Another attempt to sort out the dialog appearing behind other windows.
This commit is contained in:
@@ -72,9 +72,12 @@ namespace ASCOM.Meade.net
|
|||||||
return profileProperties;
|
return profileProperties;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
[DllImport("user32.dll")]
|
||||||
|
private static extern bool SetForegroundWindow(IntPtr hWnd);
|
||||||
|
|
||||||
private void SetupDialogForm_Shown(object sender, EventArgs e)
|
private void SetupDialogForm_Shown(object sender, EventArgs e)
|
||||||
{
|
{
|
||||||
BringToFront();
|
SetForegroundWindow(Handle);
|
||||||
Activate();
|
Activate();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user