hi zusammen !
kann man bei windows7 die error msg ausschalten wenn ein programm crasht?
z.b. wenn redvex crasht kommt bei mir immer eine error msg ;)
das ist zum removen von d2 error
kann man bei windows7 die error msg ausschalten wenn ein programm crasht?
z.b. wenn redvex crasht kommt bei mir immer eine error msg ;)
das ist zum removen von d2 error
viell kann man das so umschreiben das es redvex error removt :)Quote:
$D2PathName=IniRead(@ScriptDir & "\Config.ini", "Settings", "D2PathName", "")
while 1
sleep(1000)
if winexists("Diablo II Exception") Then
winkill("Diablo II Exception")
Kill()
LogEvent(0, "Diablo II Exception error has occurred, closing Diablo II and D2 error window.")
EndIf
sleep(1000)
if winexists("Diablo II Error") Then
winkill("Diablo II Error")
Kill()
LogEvent(0, "Diablo II Error has occurred, closing Diablo II and D2 error window.")
EndIf
sleep(1000)
if winexists("Diablo II Critical Error") Then
winkill("Diablo II Critical Error")
LogEvent(0, "Diablo II Critical Error has occurred (most likely trying to run more then one D2), closing Diablo II and D2 error window.")
endif
sleep(2000)
wend
func Kill()
winkill("Diablo II")
ProcessClose("Game.exe")
FileDelete($D2PathName & "\data")
FileDelete($D2PathName & "\bncache.DAT")
EndFunc
Func LogEvent($Code, $String)
$LogFile = FileOpen(@ScriptDir & "\Logs\Events.txt", 1)
Select
Case $Code = 0
FileWriteLine($LogFile, @MON & "/" & @MDAY & " " & @HOUR & ":" & @MIN & ":" & @SEC & " [I]> " & $String)
Case $Code = 1
FileWriteLine($LogFile, @MON & "/" & @MDAY & " " & @HOUR & ":" & @MIN & ":" & @SEC & " [E]> " & $String)
EndSelect
FileClose($LogFile)
EndFunc