vb实现老板键功能[图]_VB.net_黑客防线网安服务器维护基地--Powered by WWW.RONGSEN.COM.CN

vb实现老板键功能[图]

作者:黑客防线网安VB教程基地 来源:黑客防线网安VB教程基地 浏览次数:0

本篇关键词:功能老板实现Case
黑客防线网安网讯:  很久没用vb了,做了个小东西,用着还挺顺手的 :)  frmmain.frm'---------------------------------------------------------------------------------------' Author    ...

  很久没用vb了做了个小东西用着还挺顺手的 :)

  frmmain.frm

'---------------------------------------------------------------------------------------
' Author    :阿汐
' Purpose   :vb实现老板键的简单功能
'---------------------------------------------------------------------------------------
  
Sub Form_Load() Sub Form_Load()
Dim ret As Long
preWinProc = GetWindowLong(Me.hwnd, GWL_WNDPROC)
ret = SetWindowLong(Me.hwnd, GWL_WNDPROC, AddressOf Wndproc)
idHotKey = 1
'按住ctrl+q实现切换
Modifiers = MOD_CONTROL
uVirtKey = vbKeyQ
ret = RegisterHotKey(Me.hwnd, idHotKey, Modifiers, uVirtKey)
'最小花到托盘
TrayAddIcon frmmain, App.Path & "pbs.ico", "系统托盘"
End Sub
  
Sub Form_Unload() Sub Form_Unload(Cancel As Integer)
Dim ret As Long
ret = SetWindowLong(Me.hwnd, GWL_WNDPROC, preWinProc)
Call UnregisterHotKey(Me.hwnd, uVirtKey)
'退出时移出托盘图标
TrayRemoveIcon
End Sub
  
Sub Form_Resize() Sub Form_Resize()
  
    '窗口最小化
    If Me.WindowState = vbMinimized Then Me.Hide
  
End Sub
  
Sub Form_MouseMove() Sub Form_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
  
    '气泡单击时的鼠标事件
    Dim Result As Long
    Dim cEvent As Single
    cEvent = X / Screen.TwipsPerPixelX
  
    Select Case cEvent
  
    Case MouseMove
        TrayBalloon frmmain, "一键隐藏程序 v0.1 By 阿汐", NIIF_INFO
    Case LeftUp
  
    Case LeftDown
        frmmain.WindowState = 0
        frmmain.Show
    Case LeftDbClick
        
    Case MiddleUp
      
    Case MiddleDown
        
    Case MiddleDbClick
        
    Case RightUp
        
    Case RightDown
  
    Case RightDbClick
  
    Case BalloonClick
  
    End Select
  
End Sub
  
Sub Label1_Click() Sub Label1_Click()
  
End Sub
  
Sub Label2_Click() Sub Label2_Click()
  
End Sub

    黑客防线网安服务器维护方案本篇连接:http://www.rongsen.com.cn/show-14707-1.html
网站维护教程更新时间:2012-04-03 01:12:48  【打印此页】  【关闭
我要申请本站N点 | 黑客防线官网 |  
专业服务器维护及网站维护手工安全搭建环境,网站安全加固服务。黑客防线网安服务器维护基地招商进行中!QQ:29769479

footer  footer  footer  footer