#region TraviBlog

I remember when I used to change this tagline on a weekly basis

Replacing Notepad with Notepad 2 on XP SP3, the easiest way possible

After installing SP3 on XP I noticed that Notepad was reverted back to its crappy self, so I decided to write a handy batch script to install Notepad2 again. This script will work in XP SP2+. Place the batch file in the same directory as notepad2.exe and run it.

InstallNotepad2XP.bat

@echo off
echo *IMPORTANT*
echo This will kill all open instances of Notepad.
echo To cancel, end this batch file now (ctrl+c), or hit any key to continue.
pause
echo Killing all instances of notepad running...
TASKKILL /F /IM notepad.exe /T
echo Backing up...
call :backup %systemroot%\servicepackfiles\i386
call :backup %systemroot%
call :backup %systemroot%\System32
call :backup %systemroot%\System32\dllcache
echo Installing...
copy notepad2.exe %systemroot%\servicepackfiles\i386\notepad.exe /y
copy notepad2.exe %systemroot%\notepad.exe /y
copy notepad2.exe %systemroot%\System32\notepad.exe /y
copy notepad2.exe %systemroot%\System32\dllcache\notepad.exe /y
echo Done.
pause
goto :end
:backup
call set npath=%1
set count=0
for %%i in (%npath%\notepad.original*.exe) do (
set nname=%%i
set /a count=count+1
)
echo backing up to %npath%\notepad.original%count%.exe
copy %npath%\notepad.exe %npath%\notepad.original%count%.exe /y
:end

posted on Wednesday, July 16, 2008 1:21 PM

Feedback

# re: Replacing Notepad with Notepad 2 on XP SP3, the easiest way possible 9/15/2008 12:21 PM Mike

Works great! Thanks!

# re: Replacing Notepad with Notepad 2 on XP SP3, the easiest way possible 11/22/2008 11:03 AM Heidi

Thanks for this! I replaced it with Villian's Notepad 2008. At first it didn't work, but then I realized it didn't work because it didn't have all the .dll files the program needed to run correctly. I copied the .dll files to the correct place, and now it works!

You're amazing! Now I'm off to figure out how to get rid of that stupid drwatson again. I got rid of him on Win XP SP2, but now I sadly have Win XP SP3, so I guess I have to boot him away again :(

Leave Comments
if you can read this, your browser sucks.
upgrade:
*firefox* | mozilla | netscape | safari

#endregion