#NoTrayIcon
#region ;**** 参数创建于 ACNWrapper_GUI ****
#PRE_Icon=F:\lamox\vstart\rh\ico\box.ico
#PRE_Outfile=pc32.exe
#PRE_Outfile_x64=pc64.exe
#PRE_Compression=4
#PRE_Compile_Both=y
#PRE_Res_Comment=AU3程序写入,发现关键字自动关闭程序
#PRE_Res_Description=关闭本程序快捷键为WIN+ESc
#PRE_Res_Fileversion=0.11.0.0
#PRE_Res_LegalCopyright=RX-rh开发,如有需要可联系我获取源码
#PRE_Res_requestedExecutionLevel=None
#PRE_Run_Tidy=y
#endregion ;**** 参数创建于 ACNWrapper_GUI ****
#include <Misc.au3>
#include <Process.au3>
HotKeySet("!{ESC}", "ext");退出快捷键为ALT+esc键
While 1
$INI = @ScriptDir & "\rhc.ini"
IniRead($INI, "关键字", "视频", "close")
If FileExists($INI) Then
rx()
Else
Local $hDownload = InetGet("http://rhci.vicp.cc/killset/rhc.ini", @ScriptDir & "\rhc.ini", 1, 1)
Do
Sleep(250)
Until InetGetInfo($hDownload, 2) ; 检查下载是否完成.
InetClose($hDownload) ; 关闭句柄,释放资源.
rx()
EndIf
Sleep(2000) ;1000 等于1秒
WEnd
Func rx()
$INI = IniReadSection(@ScriptDir & "\rhc.ini", "关键字")
If $INI = 1 Then
IniWrite(@ScriptDir & "\rhc.ini", "关键字", "视频", "close")
IniWrite(@ScriptDir & "\rhc.ini", "关键字", "锁定", "pclock")
IniWrite(@ScriptDir & "\rhc.ini", "关键字", "重启", "reboot")
IniWrite(@ScriptDir & "\rhc.ini", "关键字", "关机", "powred")
MsgBox(64, "提示", " 首次生成配置文件,请按格式写入文件,并保存")
Sleep(250)
ShellExecute("rhc.ini", "", @ScriptDir, "edit"); 打开配置文件并编辑
Exit
Else
For $i = 1 To $INI[0][0]
If WinExists($INI[$i][0]) Then
If $INI[$i][1] = "close" Then
WinKill($INI[$i][0])
EndIf
If $INI[$i][1] = "pclock" Then
MsgBox(4, "", "因违反操作,本机将于10秒后锁定!", 5)
Sleep(5000)
Run(@ComSpec & " /c " & 'rundll32.exe user32.dll,LockWorkStation', "", @SW_HIDE)
EndIf
If $INI[$i][1] = "reboot" Then
MsgBox(4, "提醒", "本机将于30秒后重启!", 30)
Shutdown(6)
EndIf
If $INI[$i][1] = "powred" Then
MsgBox(4, "提醒", "本机将于30秒后关机!", 30)
Shutdown(5)
EndIf
EndIf
Next
EndIf
EndFunc ;==>rx
Func ext()
Exit
EndFunc ;==>ext
只能说这些,仁者见仁,智者见智,源码就这,至于你拿去做啥,我就管不到了