Private Declare Function FindWindow Lib "user32" Alias "FindWindowA" (ByVal lpclassname As String, ByVal lpWindowName As String) As Long
Private Declare Function FindWindowEx Lib "user32" Alias "FindWindowExA" (ByVal hWnd1 As Long, ByVal hWnd2 As Long, ByVal lpsz1 As String, ByVal lpsz2 As String) As Long
Private Declare Function ShowWindow Lib "user32" (ByVal hwnd As Long, ByVal nCmdShow As Long) As Long
Const sTrayWindow = "Shell_TrayWnd"
Const sTrayNotify = "TrayNotifyWnd"
Const sStartButton = "Button"
Const sAppSwitchBar = "ReBarWindow32"
Const sAppSwitch = "MSTaskSwWClass"
Const sAppIcon = "ToolbarWindow32"
Const sTrayClock = "TrayClockWClass"
Const sDesktopIcon = "ShellDll_DefView"
Const sProgman = "Progman"Const SW_SHOW = 5
Const SW_HIDE = 0Public Function HideTray() As Boolean
wnd = FindWindow(sTrayWindow, vbNullString)
wnd = FindWindowEx(wnd, 0, sTrayNotify, vbNullString)
ShowWindow wnd, SW_HIDE
Public Function ShowTray() As Boolean
wnd = FindWindow(sTrayWindow, vbNullString)
wnd = FindWindowEx(wnd, 0, sTrayNotify, vbNullString)
ShowWindow wnd, SW_SHOW
Private Declare Function FindWindowEx Lib "user32" Alias "FindWindowExA" (ByVal hWnd1 As Long, ByVal hWnd2 As Long, ByVal lpsz1 As String, ByVal lpsz2 As String) As Long
Private Declare Function ShowWindow Lib "user32" (ByVal hwnd As Long, ByVal nCmdShow As Long) As Long
Const sTrayWindow = "Shell_TrayWnd"
Const sTrayNotify = "TrayNotifyWnd"
Const sStartButton = "Button"
Const sAppSwitchBar = "ReBarWindow32"
Const sAppSwitch = "MSTaskSwWClass"
Const sAppIcon = "ToolbarWindow32"
Const sTrayClock = "TrayClockWClass"
Const sDesktopIcon = "ShellDll_DefView"
Const sProgman = "Progman"Const SW_SHOW = 5
Const SW_HIDE = 0Public Function HideTray() As Boolean
wnd = FindWindow(sTrayWindow, vbNullString)
wnd = FindWindowEx(wnd, 0, sTrayNotify, vbNullString)
ShowWindow wnd, SW_HIDE
Public Function ShowTray() As Boolean
wnd = FindWindow(sTrayWindow, vbNullString)
wnd = FindWindowEx(wnd, 0, sTrayNotify, vbNullString)
ShowWindow wnd, SW_SHOW
解决方案 »
- 非常急!关于Excel 和sql导入导出,想完整代码!
- 取出特定记录的前后 二条数据?
- 一个等待用户响应的问题。
- 请教:如何解决ado引用不能正常关闭的问题?
- 关于CommonDialog控件的问题,在线等候,急!
- 请问一个符号的意思!!!!!!!!!!!!!!!!!!!!!!11
- 表结构的转换。请给出思路及语言结构,谢谢。(vb+access)
- 怎么统计该字段所有记录的和??
- VB中创建了一个word对象,打印其中的内容,如果文件很大,刚打印就关WORD会出错,有什么好办法能判断打完没打完吗?
- WINIO如何记录连续按键
- 请教:HTMLHELP打开的帮助文件?
- 各位有什么好用的函数、子程序请贴出来,300分不够再加
可不可以通过找到QQ的句柄,然后用Shell_NotifyIcon(Shell_NotifyIconA)实现呢!同志们不要急,下午5:00,准时给分。