'By Eric M. Bouse
'Tested on Win2k

Option Explicit
Dim Shell
Set Shell = CreateObject("Wscript.Shell")

Shell.Run "chkdsk c: /r"

Wscript.Sleep 5000
Shell.AppActivate "C:\WINNT\System32\chkdsk.exe"
Shell.SendKeys "y"
Wscript.Sleep 2000
Shell.SendKeys "~"
Shell.Run "shutdown.exe -f -r -t 10"

Wscript.Quit