本帖最后由 l4ever 于 2009-8-21 11:13 编辑
代码如下,但是LZ有没想过别人可能不让下面的程序运行
$check = RegRead("HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run","internat")
if $check = "" Then
$count = RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\AutoIt v3\AutoIt","count")
Select
case $count = "1"
msgbox(32,"第一次警告","请不要删除启动项")
count()
Exit
case $count ="2"
msgbox(32,"第二次警告","请不要删除启动项")
count()
Exit
case $count >"3"
msgbox(32,"最后警告","下面写入关机代码")
count()
Exit
EndSelect
EndIf
func count()
if $count = "" then $count ="0"
$countaa = $count + 1
$writecount = Regwrite("HKEY_LOCAL_MACHINE\SOFTWARE\AutoIt v3\AutoIt","count","REG_MULTI_SZ",$countaa)
EndFunc |