I have an application that I need to kill the taskbar and then bring it back without closing the application. I am using two API's in a module:
Private Declare Function PostMessage Lib "user32.dll" Alias "PostMessageA" (ByVal hwnd As Long, ByVal wMsg As Long, ByVal wParam As Long, ByVal lParam As Long) As Long
Private Declare Function FindWindow Lib "user32.dll" Alias "FindWindowA" (ByVal lpClassName As String, ByVal lpWindowName As String) As Long
Then I have sub in the same module to kill the taskbar which I call from the standard module:
Public Sub KillApplicationBar()
Dim hwnd As Long, x As Long, y As Long
hwnd = FindWindow("Shell_TrayWnd", ""
PostMessage hwnd, 2, 0, 0
End Sub
I have tried using the SendMessage API but cannot get the taskbar back without rebooting. What do I need to look at?
Thank you in advance for any help!
Private Declare Function PostMessage Lib "user32.dll" Alias "PostMessageA" (ByVal hwnd As Long, ByVal wMsg As Long, ByVal wParam As Long, ByVal lParam As Long) As Long
Private Declare Function FindWindow Lib "user32.dll" Alias "FindWindowA" (ByVal lpClassName As String, ByVal lpWindowName As String) As Long
Then I have sub in the same module to kill the taskbar which I call from the standard module:
Public Sub KillApplicationBar()
Dim hwnd As Long, x As Long, y As Long
hwnd = FindWindow("Shell_TrayWnd", ""
PostMessage hwnd, 2, 0, 0
End Sub
I have tried using the SendMessage API but cannot get the taskbar back without rebooting. What do I need to look at?
Thank you in advance for any help!