c# - get focus on first form -


I have two forms form1 and form2 I navigate to form2 using a button in form1 I have in Form 2 There is a button control; Click on the button, I show the message box when the message box arrives, it also loses the focus of Form 1, but I want it to not lose the focus of Form 1. I have no worries with Form 2.

There is no message that looks like a dialog box. Like Aliren Peer said, you should make a form like a message box with a label and button and should use it like this.

  MessageForm = New MessageForm.Show ();   

If you use ShowEdio_log then this message is going to be the same thing as the box.

In your Form 1, you do not have any reason to keep TopMost property = true in front of it all the time, but this is your form at the top of all other open programs. Is going to be

After the messagebox is closed by the user, another solution will be solved (this is not a bad option) you can call Form 1 at BringtoFront (). To do this, you can pass the example of Form 1 in the method shown in Show2. Use that parameter in your form2 constructor.

Comments

Popular posts from this blog

c - Mpirun hangs when mpi send and recieve is put in a loop -

python - Apply coupon to a customer's subscription based on non-stripe related actions on the site -

java - Unable to get JDBC connection in Spring application to MySQL -