
Private Declare Function GetAsyncKeyState Lib "user32" (ByVal vkey As Long) As Integer
'申明api
Private Function MyHotKey(vKeyCode) As Boolean
MyHotKey = ((GetAsyncKeyState(vKeyCode) <0))
End Function
Private Sub Form_Load()
Timer1.Interval = 100 '定时检测
Me.Visible = False
End Sub
Private Sub Timer1_Timer()
If MyHotKey(vbKeyO) Then Me.Visible = True
'还可以换槐核洞仿成调用其他函数
End Sub
新建个EXE工程,把Form1的Visible属性设为False.给工具箱加入MicrosoftInternet
Control,并在窗体猜咐上嫌兆春加入一个这芹耐个控件.
代码:
Private
Sub
Form_Load()
Me.Timer1.Interval
=
10
*
60
*
1000
Me.Timer1.Enabled
=
True
End
Sub
Private
Sub
Timer1_Timer()
Me.WebBrowser1.Navigate
"http://网址"
End
Sub
欢迎分享,转载请注明来源:内存溢出
微信扫一扫
支付宝扫一扫
评论列表(0条)