#include <ButtonConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
#include <ACN_String.au3>
#Region ### START Koda GUI section ### Form=
$Form1 = GUICreate("数字 字母", 241, 105, 388, 180)
$Button1 = GUICtrlCreateButton("数字", 24, 32, 73, 41)
$Button2 = GUICtrlCreateButton("字母", 128, 32, 83, 41)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###
While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
Exit
Case $Button1
While 1
Sleep(1000)
SendX("1",0)
Send("{ENTER}")
Sleep(1000)
SendX("2",0)
Send("{ENTER}")
SendX("3",0)
Send("{ENTER}")
Sleep(1000)
SendX("4",0)
Send("{ENTER}")
Sleep(1000)
SendX("5",0)
Send("{ENTER}")
Sleep(1000)
SendX("6",0)
Send("{ENTER}")
Sleep(1000)
SendX("7",0)
Send("{ENTER}")
Sleep(1000)
SendX("8",0)
Send("{ENTER}")
Sleep(1000)
SendX("9",0)
Send("{ENTER}")
Sleep(1000)
SendX("10",0)
Send("{ENTER}")
Sleep(1000)
SendX("11",0)
Send("{ENTER}")
Sleep(1000)
SendX("12",0)
Send("{ENTER}")
Sleep(1000)
SendX("13",0)
Send("{ENTER}")
Sleep(1000)
SendX("14",0)
Send("{ENTER}")
Sleep(1000)
SendX("15",0)
Send("{ENTER}")
Sleep(1000)
SendX("16",0)
Send("{ENTER}")
Sleep(1000)
SendX("17",0)
Send("{ENTER}")
Sleep(1000)
SendX("18",0)
Send("{ENTER}")
Sleep(1000)
SendX("19",0)
Send("{ENTER}")
WEnd
Case $Button2
While 1
Sleep(1000)
SendX("A",0)
Send("{ENTER}")
Sleep(1000)
SendX("B",0)
Send("{ENTER}")
SendX("C",0)
Send("{ENTER}")
Sleep(1000)
SendX("D",0)
Send("{ENTER}")
Sleep(1000)
SendX("E",0)
Send("{ENTER}")
Sleep(1000)
SendX("F",0)
Send("{ENTER}")
Sleep(1000)
SendX("G",0)
Send("{ENTER}")
Sleep(1000)
SendX("H",0)
Send("{ENTER}")
Sleep(1000)
SendX("I",0)
Send("{ENTER}")
Sleep(1000)
SendX("J",0)
Send("{ENTER}")
WEnd
EndSwitch
WEnd
还怎么使其有按下其中按钮后循环相应的事件,按住热键后暂停,再按下热键就继续循环,当按下其他按钮后终止其循环并运行所按下按钮触发的事件? 求助大侠们帮忙。