#include <ButtonConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
#Region ### START Koda GUI section ### Form=
$Form1 = GUICreate("Form1", 139, 254, 193, 125)
$Checkbox1 = GUICtrlCreateCheckbox("注册1", 32, 24, 105, 33)
$Checkbox2 = GUICtrlCreateCheckbox("注册2", 32, 64, 105, 25)
$Checkbox3 = GUICtrlCreateCheckbox("注册3", 32, 104, 73, 17)
$Checkbox4 = GUICtrlCreateCheckbox("注册4", 32, 144, 89, 17)
$Button1 = GUICtrlCreateButton("全选", 16, 192, 97, 25, 0)
$Button2 = GUICtrlCreateButton("全不选", 16, 220, 97, 25, 0)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###
While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
Exit
Case $Button1
For $i=1 to 4
$T="Checkbox"&$i
GUICtrlSetState(Eval($T),$GUI_CHECKED)
Next
Case $Button2
For $i=1 to 4
$T="Checkbox"&$i
GUICtrlSetState(Eval($T),$GUI_UNCHECKED)
Next
EndSwitch
WEnd
|