一直对AU3 这部份 GUI的代码不理解。。。
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
$Form1 = Guicreate("Form 1", 400, 401, -1, -1)
$Button1 = GuiCtrlCreateButton("Button1", 130, 280, 50, 20)
$Checkbox1 = GUICtrlCreateCheckbox("Checkbox1", 80, 40, 100, 20)
$Checkbox2 = GUICtrlCreateCheckbox("Checkbox2", 80, 70, 100, 20)
$Checkbox3 = GUICtrlCreateCheckbox("Checkbox3", 80, 100, 100, 20)
$Checkbox4 = GUICtrlCreateCheckbox("Checkbox4", 80, 130, 100, 20)
$Checkbox5 = GUICtrlCreateCheckbox("Checkbox5", 80, 160, 100, 20)
$Checkbox6 = GUICtrlCreateCheckbox("Checkbox6", 80, 190, 100, 20)
$Checkbox7 = GUICtrlCreateCheckbox("Checkbox7", 80, 220, 100, 20)
GuiSetState(@SW_SHOW)
While 1
$Msg = GUIGetMsg()
Switch $Msg
Case $GUI_EVENT_CLOSE
Exit
Case $Button1
Case $Checkbox1
Case $Checkbox2
Case $Checkbox3
Case $Checkbox4
Case $Checkbox5
Case $Checkbox6
Case $Checkbox7
EndSwitch
Wend
创建控件的部份能理解,
While 1
$Msg = GUIGetMsg()
Switch $Msg
Case $GUI_EVENT_CLOSE
Exit
这部份的作用是什么? 控制行为 ? 是否可有可无 ?
想理清一下思路。。麻烦那位大大帮助一下....
[ 本帖最后由 黑琦一护 于 2009-2-6 13:56 编辑 ] |