|
本帖最后由 srhack 于 2012-3-22 09:47 编辑
感谢ACN!!感谢Auotit感谢CCTV,..
感谢,,坛里群里的各位帮助过我的兄弟,,,
虽然只是一个小小的东东,,在高手眼里就分分钟的小软件,.,我给折腾了一两天,,,汗,,
但是我感觉到了努力后那种成功的心情,,!
以后会努力好好学习帮助像我这样刚刚接触的新同志。。。#include <ButtonConstants.au3>
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
#region ### START Koda GUI section ### Form=
$Form1 = GUICreate("软件自动安装网吧版--by.IeAnDgvt QQ:12079110", 483, 410, -1, -1)
$Pic1 = GUICtrlCreatePic("D:\Personal\桌面\124.jpg", 0, 0, 481, 129)
$Checkbox1 = GUICtrlCreateCheckbox("Microsoft .NET Framework2.0", 48, 144, 185, 25)
$Checkbox2 = GUICtrlCreateCheckbox("搜狗拼音网吧版", 291, 144, 113, 25)
$Checkbox3 = GUICtrlCreateCheckbox("OFFICE 2003 简化版", 48, 200, 137, 25)
$Checkbox4 = GUICtrlCreateCheckbox("Realplay10.6经典版", 291, 196, 129, 25)
$Checkbox5 = GUICtrlCreateCheckbox("远古播放器2010网吧版", 48, 248, 145, 25)
$Checkbox6 = GUICtrlCreateCheckbox("迅雷无广告版", 291, 247, 97, 25)
$Button1 = GUICtrlCreateButton("安装", 88, 296, 65, 25)
$Button2 = GUICtrlCreateButton("退出", 279, 296, 65, 25)
$Label1 = GUICtrlCreateLabel("请在你将要安装的软件上打钩,然后点击安装即可", 16, 360, 268, 17)
$Label2 = GUICtrlCreateLabel("请根据需要安装,附加软件可以不选!", 16, 384, 208, 17)
GUISetState(@SW_SHOW)
#endregion ### END Koda GUI section ###
Local $Checkbox
While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE, $Button2
Exit
Case $Button1
GUICtrlSetState($Button1,$GUI_DISABLE)
GUICtrlSetState($Button2,$GUI_DISABLE)
Local $bool = False
For $i = 1 To 6
$t = "checkbox" & $i
If GUICtrlRead(Eval($t)) = $GUI_CHECKED Then
$bool = True
setup($i)
EndIf
Next
if $bool Then
_end()
Else
MsgBox(48, '', '一个也没有选中')
EndIf
GUICtrlSetState($Button1,$GUI_ENABLE)
GUICtrlSetState($Button2,$GUI_ENABLE)
EndSwitch
WEnd
Func setup($i)
Switch $i
Case 1
TrayTip("","正在安装Microsoft .NET Framework2.0,请勿动鼠标键盘",3)
Sleep(6000)
RunWait("1.exe")
Case 2
TrayTip("","正在安装搜狗拼音网吧版,请勿动鼠标键盘",3)
Sleep(6000)
RunWait("2.exe")
Case 3
TrayTip("","正在安装OFFICE 2003 简化版,请勿动鼠标键盘",3)
Sleep(6000)
RunWait("3.exe")
Case 4
TrayTip("","正在安装Realplay10.6经典版,请勿动鼠标键盘",3)
Sleep(6000)
RunWait("4.exe")
Case 5
TrayTip("","正在安装远古播放器2010网吧版,请勿动鼠标键盘",3)
Sleep(6000)
RunWait("5.exe")
Case 6
TrayTip("","正在安装迅雷无广告版,请勿动鼠标键盘",3)
Sleep(6000)
RunWait("5.exe")
EndSwitch
EndFunc
Func _end()
MsgBox(48, '', '所有软件这安装结束!',3)
Exit
EndFunc
下面贴出我想要的效果完整代码: |
评分
-
查看全部评分
|