How to make sure that a form open infront of another form

Is there any catch or any way I can make sure a form being called from the original form always opens up in front of that original form? I sometimes get the second form show up behind the first form?

Thanks in advance.
Who is Participating?
käµfm³d 👽Connect With a Mentor Commented:
Do you have the TopMost property of the second form set to True?
Chris MillardCommented:
You could use Me.Activate() as the first command when the second form loads.
cmdolcetAuthor Commented:
Is this before the say for example
cmdolcetAuthor Commented:
I can check, should I also check to see if I have it set on form form1?
käµfm³d 👽Commented:
I cannot remember who wins out if two forms have TopMost set, and one form shows the other. If you don't need to be able to access the main form while the second form is displayed, then showing the second form via ShowDialog should give the desired effect (without having to set TopMost). The second form will be modal, so you won't have access to the main form until the second form is closed.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.