下面是帮助里的示例,我看来看去还是不怎么懂啊,
GUICtrlRead,GUICtrlGetState分别读取的是什么啊?怎么一个是1一个是80?
我自己根据说明来理解,感觉都应该是$GUI_CHECKED
#include <GUIConstantsEx.au3>
Opt('MustDeclareVars', 1)
Example()
Func Example()
Local $n, $msg
GUICreate("My GUI (GetControlState)")
$n = GUICtrlCreateCheckbox("checkbox", 10, 10)
GUICtrlSetState(-1, 1) ; checked
GUISetState() ; will display an empty dialog box
; Run the GUI until the dialog is closed
While 1
$msg = GUIGetMsg()
If $msg = $GUI_EVENT_CLOSE Then ExitLoop
WEnd
MsgBox(0, "state", StringFormat("GUICtrlRead=%d\nGUICtrlGetState=%d", GUICtrlRead($n), GUICtrlGetState($n)))
EndFunc ;==>Example
[ 本帖最后由 macemo 于 2008-9-23 15:56 编辑 ] |