trace_off.cmd 432 B

1234567891011121314151617181920
  1. @echo off
  2. chcp 866
  3. echo Debug trace off utility
  4. echo Remove debug trace parameters
  5. reg delete "HKLM\SYSTEM\CurrentControlSet\Services\sncc0\Trace" /f
  6. IF errorlevel 1 GOTO :error
  7. echo.
  8. echo Trace is turned off, computer should be restarted
  9. echo Restart computer right now (Y/N)?
  10. set /p answer=""
  11. IF /I %answer% EQU Y shutdown /r
  12. EXIT 0
  13. :error
  14. echo An error occured. Run command as administrator.
  15. pause
  16. EXIT 1