How to Open Notepad++ Associated Files in a New Window

Recently I’ve been messing around with the customization settings for Notepad++. Although the program allows you to change a lot about its appearance (syntax highlighting, remove that pesky toolbar) I immediately noticed that there were no settings that allow you open multiple Notepad++ windows. Instead, when you open a new file it just adds it as a tab to your current window. After googling for a bit I found a couple solutions.

Notepad++ has a command line switch, “-multiInst”, which will open a new instance of Notepad++ in a new window when it’s run. An easy solution to our problem is to stick this switch on the end of your Notepad++ shortcut. Unfortunately, I usually open my text editor by double clicking a text editable file, and this doesn’t change that behavior.

Some people have suggested creating an empty “asNotepad.xml” file in the same directory as Notepad++.exe. This does exactly what we want, except that it also disables the tab bar, which I want to keep enabled.

The last solution is to edit the Windows registry files. This is the approach I took, since it allowed me to set up Notepad++ exactly how I wanted it.

Make Notepad++ associated files open in their own window:

  • Open the registry editor (Windows Key + R, type in regedit and hit enter).
  • Navigate to 

Computer\HKEY_CLASSES_ROOT\Applications\notepad++.exe\shell\open\command

  • If you ever created “asNotepad.xml” this key will already exist, otherwise just make the keys yourself (Right Click->New->Key).
  • Open (Default) REG_SZ
  • If the key already existed, just add -multiInst to the end
  • If you made the key yourself, Enter "yourpath" "%1" -multiInst

My key value looked like this:
"C:\Program Files (x86)\Notepad++\notepad++.exe" "%1" -multiInst

Now when we double click files associated with Notepad++ they open in a new window, just like we wanted! There still is one small problem, when you right click on a file and click “Edit with Notepad++”, it still opens the file in an existing window as a new tab.

Make the “Edit with Notepad++” context menu option open files in their own window:

  • Open the registry editor.
  • Navigate to

Computer\HKEY_CLASSES_ROOT\*\shellex\ContextMenuHandlers\Notepad++64 (the last key might be named ANotepad++64)

  • Copy the value in (Default) REG_SZ to your clipboard.

My value was:
{B298D29A-A6ED-11DE-BA8C-A68E55D89593}

  • In the toolbar go to Edit->Find
  • Paste the value into the search bar.
  • Uncheck values and data.
  • Click Find.
  • Expand the key and click on Settings
  • Double click on Custom REG_SZ
  • Set the value data to -multiInst

Now the “Edit with Notepad++” button should open files in their own windows.

Advertisements

~ by Conch Connoisseur on September 23, 2013.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

 
%d bloggers like this: