How to make notepad++ the default editor for a Windows batch file?
Change the program associated to the "Edit" verb for batch files:
- Run RegEdit (as admin)
- Navigate to
HKEY_CLASSES_ROOT\batfile\shell\edit\command
. - Modify the Default and change Value Data from
%SystemRoot%\System32\NOTEPAD.EXE %1
to"C:\Program Files (x86)\Notepad++\notepad++.exe" "%1"
- Close RegEdit.
- Right-click -> "Edit" should now open batch files in NotePad++.
Note: You may have to adjust your path to Notepad++.exe if it resides in a different folder on your system.
Also note: This is a system-wide change.