0

I have a Visual Basic .Net form (launches after the splash screen tests database connectivity) and it is not focusing above other existing windows on launch.

How do I get it to focus above all existing windows and Windows Explorer windows?

MPelletier
  • 16,256
  • 15
  • 86
  • 137
Jeremy Child
  • 172
  • 1
  • 4
  • 8

1 Answers1

3
Form.Topmost = true;

See the corresponding MSDN.

A topmost form is a form that overlaps all the other (non-topmost) forms even if it is not the active or foreground form. Topmost forms are always displayed at the highest point in the z-order of the windows on the desktop. You can use this property to create a form that is always displayed in your application, such as a Find and Replace tool window.

Johannes Rudolph
  • 35,298
  • 14
  • 114
  • 172