问题描述:
Private Sub Command1_Click()
End Sub
这个中间写什么?
按键y
延迟1秒
按键enter
延迟1秒
按键enter
延迟600秒
按键y
延迟1秒
按键enter
延迟1秒
按键enter
延迟60秒
循环..
我是个新手,谢谢大家帮忙了
问题解答:
Dim c As Integer
Dim a As Integer
Private Sub Timer1_Timer()
a = c + 1
c = a
SendKeys "y"
Select Case a
Case Is = 1
SendKeys "enter"
Case Is = 2
SendKeys "enter"
Case Is = 602
SendKeys "y"
Case Is = 603
SendKeys "enter"
Case Is = 604
SendKeys "enter"
Case Is = 664
SendKeys "enter"
a = 0
b = 0
c = 0
End Select
Label1.Caption = a
End Sub
加一个时间控件
sendkeys"y"
sendkeys"enter"按建方法,具体延时自己可以加timer控件