Rob van der Woude's Scripting Pages
Powered by GeSHi

Source code for nonagxp.bat

(view source code of nonagxp.bat as plain text)

  1. @ECHO OFF
  2. IF NOT "%OS%"=="Windows_NT"         GOTO Syntax
  3. IF NOT "%~1"==""                    GOTO Syntax
  4. VER | FIND.EXE "Windows XP" >NUL || GOTO Syntax
  5.  
  6. :: Create temporary .reg file
  7. >  "%Temp%.\nonagxp.reg" ECHO REGEDIT4
  8. >> "%Temp%.\nonagxp.reg" ECHO.
  9. >> "%Temp%.\nonagxp.reg" ECHO [HKEY_CURRENT_USER\Software\Microsoft\MessengerService]
  10. >> "%Temp%.\nonagxp.reg" ECHO "PassportBalloon"=hex:0a,00
  11. >> "%Temp%.\nonagxp.reg" ECHO.
  12. >> "%Temp%.\nonagxp.reg" ECHO [HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Applets\Tour]
  13. >> "%Temp%.\nonagxp.reg" ECHO "RunCount"=dword:00000000
  14. >> "%Temp%.\nonagxp.reg" ECHO.
  15.  
  16. :: Import settings from temporary .reg file
  17. START /WAIT REGEDIT.EXE /S "%Temp%.\nonagxp.reg"
  18.  
  19. :: Remove temporary .reg file
  20. DEL "%Temp%.\nonagxp.reg"
  21.  
  22. :: Done
  23. GOTO:EOF
  24.  
  25.  
  26. :Syntax
  27. ECHO.
  28. ECHO NoNagXP.bat,  Version 1.00 for Windows XP
  29. ECHO Disable nag screens for .NET Passport and Windows XP Pro Tour
  30. ECHO.
  31. ECHO Usage:  NONAGXP
  32. ECHO.
  33. ECHO Idea: Greg Schultz's xpnagdisabler VBScripts on
  34. ECHO http://techrepublic.com.com
  35. ECHO Converted to batch by Rob van der Woude
  36. ECHO http://www.robvanderwoude.com
  37.  

page last uploaded: 2016-12-15, 11:20