Fenčtre toujours visible

 

Public Const HWND_BOTTOM As Long = 1
Public Const HWND_TOP As Long = 0
Public Const HWND_TOPMOST As Long = -1
Public Const HWND_NOTOPMOST As Long = -2

Public Const SWP_NOSIZE As Long = &H1
Public Const SWP_NOMOVE As Long = &H2
Public Const SWP_NOZORDER As Long = &H4
Public Const SWP_NOREDRAW As Long = &H8
Public Const SWP_NOACTIVATE As Long = &H10
Public Const SWP_FRAMECHANGED As Long = &H20
Public Const SWP_DRAWFRAME As Long = SWP_FRAMECHANGED
Public Const SWP_SHOWWINDOW As Long = &H40
Public Const SWP_HIDEWINDOW As Long = &H80

Declare Function API_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

Sub cmdView()
Dim frm as frmTest
Set frm = New frmTest
    frmTest.Show
    API_SetWindowPos .hWnd, HWND_TOPMOST, 1, 1, 1, 1, SWP_NOMOVE Or SWP_NOSIZE Or SWP_SHOWWINDOW