How can I open a new form from the main thread in C#?
At this moment I open them by using this:
System.Threading.Thread t = new System.Threading.Thread(n
Go to your program.cs file and alter it so that you show your login form and then, after it has been closed, determine if you should open up another form:
It'll likely look something more or less like this:
LoginForm loginform = new LoginForm();
Application.Run(loginform);
if (loginform.DialogResult == DialogResult.Yes)
Application.Run(new MainForm());
//TODO handle error cases
Just use this
Application.Run(new OppenMainForm());