Option Explicit
Private Declare Function FindWindow Lib "user32" _ Alias "FindWindowA" (ByVal lpClassName As String, _ ByVal lpWindowName As String) As Long Private 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_HIDEWINDOW = &H80 Const SWP_SHOWWINDOW = &H40 Private Sub Command1_Click() SetWindowPos FindWindow("Shell_traywnd", ""), 0, 0, 0, 0, 0, _ SWP_HIDEWINDOW End Sub Private Sub Command2_Click() SetWindowPos FindWindow("Shell_traywnd", ""), 0, 0, 0, 0, 0, _ SWP_SHOWWINDOW End Sub |