Aman aman bu ne. Gerçek mi ya. Benim böyle olsa herhalde açılasağa kahve yapar gelirim.
Option Explicit
On Error Resume Next
Dim Wsh, Time1, Time2, Result, PathFile, MsgResult, MsgA, AppName, KeyA, KeyB, TimeDiff
MsgA = "Lütfen bütün açık uygulamaları kapatın ve TAMAM deyin."
KeyA = "HKEY_CURRENT_USER\Software\RestartTime\"
KeyB = "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run\RestartTime"
AppName = "ReBoot-Time"
Set Wsh = CreateObject("WScript.Shell")
PathFile = """" & WScript.ScriptFullName & """"
Result = wsh.RegRead(KeyA & "Times")
if Result = "" then
MsgResult = Msgbox (MsgA, vbOKCancel, AppName)
If MsgResult = vbcancel then WScript.Quit
Wsh.RegWrite KeyA & "Times", left(Time,8), "REG_SZ"
Wsh.RegWrite KeyB, PathFile, "REG_SZ"
Wsh.Run "cmd /c Shutdown -r -t 00", false, 0
else
Wsh.RegDelete KeyA & "Times"
Wsh.RegDelete KeyA
Wsh.RegDelete KeyB
TimeDiff = DateDiff("s",Result,left(Time,8))
MsgBox "Bilgisayarınızın yeniden baslatılması " & TimeDiff & " saniye surdu", VbInformation, AppName
end if
wscript.Quit
Bu script i daha önce görmüşsündür bu forumdan aldım da bulamıyorum tekrar. Bakınca ne olduğu zaten belli oluyo. Bi çalıştırır mısın vbs uzantılı, kaç saniyede reboot yapacak. Çok merak ettim, işini de bölecem ama. Benim 44 saniye çıktı.