Hallo Stephan,
mach einfach Folgendes:
' Deklaration vorweg
Declare Function SetWindowPos Lib "user32" (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
Const SWP_NOSIZE = &H1
Const SWP_NOMOVE = &H2
Const HWND_TOP = 0
Const HWND_BOTTOM = 1
Const HWND_TOPMOST = -1
Const HWND_NOTOPMOST = -2
' Fenster topmost setzen
SetWindowPos Me.hWnd, _
HWND_TOPMOST, _
0, _
0, _
0, _
0, _
SWP_NOSIZE Or SWP_NOMOVE
' Fenster nicht topmost setzen
SetWindowPos Me.hWnd, _
HWND_NOTOPMOST, _
0, _
0, _
0, _
0, _
SWP_NOSIZE Or SWP_NOMOVE
Sollte so klappen. Kann man aber auch noch schöner verpacken.
Keep hacking.
Gruß, Armin
Eine Antwort auf diesen Beitrag verfassen (mit Zitat/Zitat des Beitrags) IP