Hello;
How can I make a window look modally to the whole system ?
Printable View
Hello;
How can I make a window look modally to the whole system ?
You could use the SetWindowPos API function.
Code:Private Declare Function SetWindowPos Lib "user32" _
Alias "SetWindowPos" (ByVal hwnd As Long, ByVal _
hWndInsertAfter As Long, ByVal x As Long, ByVal y As _
Long, ByVal cx As Long, ByVal cy As Long, ByVal wFlags _
As Long) As Long
Private Sub Form_Load()
SetWindowPos hwnd, -1, 0, 0, 0, 0, 3
End Sub
And then you can use the LockWindowUpdate API function to lock every other window so only yours can be accessed.
Code:Private Declare Function LockWindowUpdate Lib "user32" (ByVal hwndLock As Long) As Long