Private Declare Function SetWindowPos Lib "user32.dll" (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 Const HWND_TOP As Long = 0 Private Const HWND_TOPMOST As Long = -1 Private Const HWND_NOTOPMOST As Long = -2 Private Const SWP_NOMOVE As Long = &H2 Private Const SWP_NOSIZE As Long = &H1
Per far diventare form in primo piano:
SetWindowPos Form1.hwnd, HWND_TOPMOST, 0, 0, 0, 0, SWP_NOMOVE + SWP_NOSIZE
Aggiungi un commento