Do not go to another FORM1 while open FORM2 esiver

Asked

Viewed 379 times

1

Suppose you have two Forms, the first Form1 is the main screen to which you give an option to open any other form, when any form is open, the user cannot go to the main form until you close/close form2.

How do I do that?

1 answer

1


You can use . Showdialog();

Example:

Form2 form=new Form2();
form.ShowDialog();

Until the user closes the Form2 screen, he will not be able to do anything on the Form1 screen

  • 1

    Thank you so much for your help. That’s just what I needed!

Browser other questions tagged

You are not signed in. Login or sign up in order to post.