QQ五笔自动安装程序
学了十几天的AU3了,手头资料很少,找了很久才遇到这网上,可下载好多都要金币买,下载还要20块,可怜的新人没金币,所以也发发个自动安装程序来赚点币币。Local Const $strTitle="QQ五笔输入法2.0安装向导"
Local Const $ExitTitle="QQ五笔输入法2.0安装向导"
Local Const $ExitText="您确实要退出“QQ五笔输入法2.0”安装向导?"
Local Const $strText1="欢迎使用“QQ五笔输入法2.0”安装向导"
Local Const $strText2="授权协议"
Local Const $strText3="选择安装位置"
Local Const $strText4="属性设置"
Local Const $strText5="安装完成"
Run("QQWubi_Setup_2.0.313.400.exe")
Sleep(500)
if WinExists("QQ五笔输入法2.0安装向导","您已经安装了该版本QQ五笔输入法") Then
ControlDisable("QQ五笔输入法2.0安装向导","您已经安装了该版本QQ五笔输入法","Button1")
WinActivate("QQ五笔输入法2.0安装向导","您已经安装了该版本QQ五笔输入法")
ControlClick("QQ五笔输入法2.0安装向导","您已经安装了该版本QQ五笔输入法","Button2")
Exit
EndIf
WinWaitActive($strTitle,$strText1)
ClickCancelBtn($strTitle,$strText2,$ExitTitle,$ExitText)
ControlClick($strTitle,$strText1,"Button2")
WinWaitActive($strTitle,$strText2)
ClickCancelBtn($strTitle,$strText3,$ExitTitle,$ExitText)
ControlClick($strTitle,$strText2,"Button2")
WinWaitActive($strTitle,$strText3)
ClickCancelBtn($strTitle,$strText4,$ExitTitle,$ExitText)
ControlClick($strTitle,$strText3,"Button2")
WinWaitActive($strTitle,$strText4)
ClickCancelBtn($strTitle,$strText5,$ExitTitle,$ExitText)
ControlClick($strTitle,$strText4,"Button2")
WinWaitActive($strTitle,$strText5)
ControlClick($strTitle,$strText5,"Button4")
ControlClick($strTitle,$strText5,"Button2")
Func ClickCancelBtn($strNextTitle,$strNextText,$strCancelTitle,$strCancelText)
Local $blnExitSetup=True
Local $num=0
While $blnExitSetup and $num<500
if WinExists($strNextTitle,$strNextText) Then
$blnExitSetup=False
ElseIf WinExists($strCancelTitle,$strCancelText) Then
WinActivate($strCancelTitle,$strCancelText)
ControlClick($strCancelTitle,$strCancelText,"Button1")
MsgBox(4096,"退出安装","你取消了程序的安装,即将退出!",2)
Exit
EndIf
$num=$num+1
WEnd
EndFunc 学习。。。。。。。 謝謝樓主分享。
页:
[1]