本帖最后由 南一 于 2012-7-16 11:01 编辑
#include <ButtonConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
#region ### START Koda GUI section ### Form=
$Form1 = GUICreate("Form1", 623, 444, 192, 124)
$Checkbox1 = GUICtrlCreateCheckbox("选择我", 72, 120, 121, 17)
$Input1 = GUICtrlCreateInput("112233", 216, 120, 169, 21, $ES_PASSWORD)
GUISetState(@SW_SHOW)
#endregion ### END Koda GUI section ###
While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
Exit
Case $Checkbox1
$Checked = GUICtrlRead($Checkbox1)
If $Checked = $GUI_CHECKED Then
GUICtrlSetState($Input1, $GUI_FOCUS)
EndIf
EndSwitch
WEnd
|