title: Closing a form during a constructor
body: <p>Is it possible to close a form while the constructor is executing (or simply to stop it showing at this stage)?</p>
  
  <p>I have the following code:</p>
  
  <pre><code>public partial class MyForm : Form
  {        
      public MyForm()
      {
          if (MyFunc())
          {
              this.Close();
          }
      }
  }
  </code></pre>
  
  <p>Which throws an ObjectDisposedException in Main(), here:</p>
  
  <pre><code>    static void Main()
      {            
          ...
  
          // Following line errors
          Application.Run(new MyForm());
      }
  </code></pre>
  
  <p>I’ve tried checking the result of MyForm like this:</p>
  
  <pre><code>static void Main()
  {            
      ...
  
      MyForm frm = new MyForm();
      if (frm != null)
      {
          // Following line errors
          Application.Run(frm);
      }
  }
  </code></pre>
  
  <p>But that doesn’t seem to help.  Can anyone tell me a way around this, please?  Maybe a way to check the form to see if it still exists?</p>