|
加入IF判断语句,运行不下去了,不加入还可以
Run("acdsee10.exe")
if WinWaitActive("ACDSee 10 ","向导将允许您修改") = 1 Then
MsgBox(0, "阿迪王", "退出,因你已安装!")
ControlClick("ACDSee 10 ","向导将允许您修改", "[class:Button;INSTANCE:2]")
ControlClick("ACDSee 10 ","是否确定要取消", "[class:Button;INSTANCE:2]")
WinWaitActive("ACDSee 10 ","您的系统尚未修改")
ControlClick("ACDSee 10 ","您的系统尚未修改", "[class:Button;INSTANCE:1]")
endif
WinWaitActive("ACDSee 10 ", "此程序受版权法与国际条约的保护")
ControlClick("ACDSee 10 ", "此程序受版权法与国际条约的保护", "[class:Button;INSTANCE:1]")
WinWaitActive("ACDSee 10 ", "请仔细阅读")
ControlClick("ACDSee 10 ", "请仔细阅读", "[class:Button;INSTANCE:3]")
WinWaitActive("ACDSee 10 ", "最终用户许可协议")
ControlClick("ACDSee 10 ", "最终用户许可协议", "[class:Button;INSTANCE:5]")
WinWaitActive("ACDSee 10 ", "选择最适合")
ControlClick("ACDSee 10 ", "选择最适合", "[class:Button;INSTANCE:5]")
WinWaitActive("ACDSee 10 ", "选择应该由")
ControlClick("ACDSee 10 ", "选择应该由", "[class:Button;INSTANCE:1]")
WinWaitActive("ACDSee 10 ", "已准备好安装")
ControlClick("ACDSee 10 ", "已准备好安装", "[class:Button;INSTANCE:1]")
WinWaitActive("ACDSee 10 ", "成功安装")
ControlClick("ACDSee 10 ", "成功安装", "[class:Button;INSTANCE:5]")
ControlClick("ACDSee 10 ", "成功安装", "[class:Button;INSTANCE:1]")
MsgBox(0, "阿迪王", "你好!安装成功!")
[ 本帖最后由 xiaolt2008 于 2008-11-29 20:55 编辑 ] |
|