This has been tested in Windows 7 64-bit edition, however should work in other versions and 32-bit editions as well.
In the days of Windows 2000, it was easy to replace "notepad.exe" with your own custom version of Notepad, such as the light-weight but powerful Notepad2. Simply find the file and overwrite.
But with Windows XP and later versions, a new feature called "Windows File Protection" prevents you from doing so.
However, you can now replace Notepad system-wide without even touching the original "notepad.exe" using a simple registry hack.
- Download Notepad2 (either 32-bit or 64-bit depending on your system). The original version will work fine. There is no need for any hacked versions such as this.
- Extract the downloaded archive into an empty folder. This folder should now contain Notepad2.exe and other supporting files.
- "Install" Notepad2 by simply copying the folder containing extracted files into "C:\Program Files" (This is not necessary but helps keep your system organized by keeping software in the Program Files folder.)
- Start Registry Editor by clicking the Start button and typing in "regedit".
- Navigate to "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Image File Execution Options"
- Right-click this folder and create a new key called "notepad.exe" (no quotes)
- Inside this new folder, create a new string value (REG_SZ) called "Debugger" (no quotes)
- Paste the full path of the new Notepad2.exe file with quotes, and add "/z" at the end. An example would be: --- "C:\Program Files\Notepad2\Notepad2.exe" /z --- but remember that your folder might be different (you can rename the folder).
- That's it! Test by running Notepad from the Start Menu and/or double-clicking some TXT files in Windows Explorer.