7,763
社区成员
发帖
与我相关
我的任务
分享
Dim sj As Date
Dim sj1 As Date
Private Sub Form_KeyDown(KeyCode As Integer, Shift As Integer)
sj = Now()
End Sub
Private Sub Form_Load()
Form1.KeyPreview = True
Timer1.Interval = 1000
sj = Now()
End Sub
Private Sub Form_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
sj = Now()
End Sub
Private Sub Timer1_Timer()
sj1 = Now()
a = DateDiff("s", sj, sj1)
If a > 10 Then
MsgBox "超过10秒,执行你设定的程序"
'这里请用shell方法打开你想要的程序
End If
End Sub