Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8465857
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T15:10:17+00:00 2026-06-10T15:10:17+00:00

I have run my program step by step, but still, I can’t find where

  • 0

I have run my program step by step, but still, I can’t find where the form.visible is set.

Here is the code of “Form1.cs”:

public Form1()
{
    InitializeComponent();
    this.Hide();
}

I added this.Hide(); but it didn’t work at all.

and I even modified “Program.cs” from:

Application.Run(new Form1());

to:

Form1 form1=new Form1();
form1.Visible = false;
Application.Run(form1);

But the main form still showed, even adding form1.Enable=false; won’t stop the form from showing. I have also tried adding this.Hide(); in Form1_Load(), it worked but the main form appeared and flashed before it was finally hidden.

I’m totally confused now. So how can I load the main form without showing it? And keep it hidden until I call this.Show();?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T15:10:19+00:00Added an answer on June 10, 2026 at 3:10 pm

    Why not override the SetVisibleCore method:

    bool showForm = false;
    
    protected override void SetVisibleCore(bool value)
    {    
       base.SetVisibleCore(showForm);
    }
    

    This will hide the form before it even opens up. With a lot of method’s you see a brief flash of the form before its .Visible or similar property is set to “hide”.

    Obviously you will need another method to flip ‘showForm’ to true when you want to display it again i.e. NotifyIcon event.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have to run some other application from my program and hide it's form.
I have a piece of templated code that is never run, but is compiled.
I'm working on some cross-platform code using OpenGL and SDL, but have immediately run
I have run this program before and it worked fine. Then I added the
I have run into a small issue in my program. I have a class
We're writing an SDK for a CAD program and have run into a slight
I've been trying to optimize a numeric program of mine, and have run into
I have written php program and uploaded on server. I want run this program
Trying to run my program in FreeBSD OS, I have the following results: $
Everytime I run the program, this mysterious error pops up saying that I have

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.