' Fenêtre visible ou pas
Public Declare Function IsWindowVisible Lib "user32" (ByVal hWnd As Long) As Boolean
' Montrer la fenêtre
Public Declare Function ShowWindowA Lib "user32" Alias "ShowWindow" (ByVal hWnd As Long, ByVal nCmdShow As Long) As Long
' Constantes associées :
Public Const SW_HIDE = 0
Public Const SW_SHOWNORMAL = 1
Public Const SW_SHOWMINIMIZED = 2
Public Const SW_SHOWMAXIMIZED = 3
Public Const SW_MAXIMIZE = 3
Public Const SW_SHOWNOACTIVATE = 4
Public Const SW_SHOW = 5
Public Const SW_MINIMIZE = 6
Public Const SW_SHOWNA = 8
Public Const SW_RESTORE = 9
'---------------------------------------------------------------------------------------
' Procedure : WindowVisible
' DateTime : 31/12/2006 14:50
' Author : Vb System Library
' Purpose : Renvoie TRUE si la fenetre est visible, FALSE dans le cas contraire
' Params : hWnd : Handle de la fenetre
'---------------------------------------------------------------------------------------
Public Function WindowVisible(ByVal hWnd As Long) As Boolean
WindowVisible = IsWindowVisible(hWnd)
End Function
'---------------------------------------------------------------------------------------
' Procedure : ShowWindow
' DateTime : 31/12/2006 14:54
' Author : Vb System Library
' Purpose : Permet de montrer une fenetre qui n'était pas visible
' Params : hWnd : Handle de la fenetre
'---------------------------------------------------------------------------------------
Public Function ShowWindow(ByVal hWnd As Long)
ShowWindowA hWnd, SW_SHOW
End Function
'---------------------------------------------------------------------------------------
' Procedure : HideWindow
' DateTime : 31/12/2006 14:54
' Author : Vb System Library
' Purpose : Permet de cacher une fenetre qui était visible
' Params : hWnd : Handle de la fenetre
'---------------------------------------------------------------------------------------
Public Function HideWindow(ByVal hWnd As Long)
ShowWindowA hWnd, SW_HIDE
End Function
Seul les admins et l'auteur du code lui même peuvent modifier ce code.