#include <GUIConstants.au3>
#Region ### START Koda GUI section ### Form=
$AForm1 = GUICreate("AForm1", 398, 281, -1, -1)
$Progress1 = GUICtrlCreateProgress(56, 176, 265, 17)
GUICtrlSetResizing(-1, $GUI_DOCKAUTO)
$Button1 = GUICtrlCreateButton("执行", 64, 232, 89, 33, 0)
$Button2 = GUICtrlCreateButton("退出", 208, 232, 89, 33, 0)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###
$time=10
AdlibEnable("djs", 10 * $time)
$wait = 0
While 1
$nMsg = GUIGetMsg()
Select
Case $nMsg=$Button1
MsgBox(0,"提示","你点了执行",10)
mr()
exitloop
Case $nMsg=$Button2
MsgBox(0,"提示","你点了退出",10)
mr()
exitloop
Case $nMsg=$GUI_EVENT_CLOSE
mr()
EndSelect
WEnd
;倒计时
Func djs()
GUICtrlSetData($Progress1, $wait)
$wait = $wait + 1
If $wait = 101 Then mr()
EndFunc
Func mr()
Exit
EndFunc
[ 本帖最后由 qq342252004 于 2008-6-28 12:45 编辑 ] |