Thats exactly what I want. Thanks!
>Kevin,
>The app doesn't really start up in the form is starts up in the static void Main() which is in a new winform app included in the form cs file. I usually move Main() out of the form file. Something like this:
>
>1. Create a new class in your project (name it MainEntryPoint.cs or whatever you want)
>2. Put the following code in that file
>
>
>using System;
>using System.Windows.Forms;
>
>namespace YourNamespaceForYourProject
>{
> /// <summary>
> /// Summary description for Main.
> /// </summary>
> public class MainEntryPoint
> {
> /// <summary>
> /// The main entry point for the application.
> /// </summary>
> [STAThread]
> static void Main()
> {
> // I usually put a try...catch here just in case an exception makes it all the way down here (better safe than sorry <s>)
> try
> {
> // some code here before you start the form
> MessageBox.Show("good morning", "good morning");
>
> // start the form here
> Application.Run(new Form1());
> }
> catch(Exception e)
> {
> MessageBox.Show(e.ToString(), "Exception caught in Main()!");
> }
> }
> }
>}
>
>
>I hope this is what you were asking and I hope it helped.
>
>Good luck.
>
>Einar
>
>>I am creating a C# Windows application. Can I have the
>>application start in a Class, instead of a form? How?
>>
>>I then want to call the form in the class. How do I do
>>that?
>>
>>Thanks
Everything makes sense in someone's mind
public class SystemCrasher :ICrashable
In addition, an integer field is not for irrational people