AutoIT: ControlSetText

1. ControlSetText :可以摆脱Send的限制,在适当的文本框位置输入用户想要输入的信息。
2. ControlGetText可以获取文本

Run("notepad.exe")
WinWait("[CLASS:Notepad]") 
ControlSetText("[CLASS:Notepad]", "", 15,"New Text Here")
Local $sText = ControlGetText("[CLASS:Notepad]","", 15)
MsgBox(0, "ControlGetText Example", "The controltext is: " & $sText)

3. ControlSend命令也可以发送指令,但是没有ControlSetText好用。

posted @ 2013-08-16 15:19  chenpassion  阅读(2367)  评论(0编辑  收藏  举报