Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

If I have Notepad++ running as administrator, I can't drag files from explorer on to it (they are rejected with the 'stop' cursor) and if I try to use the explorer extension right click 'Edit with Notepad++' it throws an error.

Opening the files using the Notepad++ 'Open' dialog, or even double clicking them in Explorer works as it should. (Note double clicking is not a solution as very few of the files I want to open are default to Notepad++)

I have UAC set to 'never notify'.

Using the hack where UAC 'admin approval mode' is disabled fixes the issue, but kills the ability to use Metro apps.

share|improve this question
    
Why are you running Notepad++ as admin? –  kinokijuf Jun 4 at 20:50
    
I'm not any more but at the time of the question it was to easily edit the hosts file (something I don't need to touch as often now) –  Luke Foreman Jun 5 at 0:08
    
It also runs as admin after it updates a plugin. I ended up here before and then I looked at the window title bar. Yup Admin. Fix: Just restart it. –  CAD bloke Jul 1 at 12:12
add comment

4 Answers 4

Another workaround is to use the standalone (zipped) version of Notepad++ instead of the installer version.

  1. Uninstall/Delete Notepad++
  2. Go to the Notepad++ download page and download the .zip or .7z package (not the exe)
  3. Unzip the contents of that package somewhere inside your user directory

Drawback to this workaround is you will of course need to create your own shortcuts and manually update your default text editor if desired. And you won't have the context-menu entry for notepad unless you hack it in there yourself.

share|improve this answer
add comment

Louis explained why you can't drag from non-admin-mode explorer into admin-mode Notepad++, and magicandre told you how get around it by running explorer in admin mode.

After experiencing a similar problem myself, I have to ask further: why are you running Notepad++ in admin mode in the first place? In my case it was because the HTML Tidy plugin which I like to use has to update a cfg file in Notepad++'s Program Files folder in order to work; and Windows 8 has Program Files locked down like crazy.

So in the end I unlocked the Notepad++ Program Files folder as outlined here: http://forums.auran.com/trainz/entry.php?115-Removing-the-security-restrictions-from-a-folder-in-the-Program-Files-folder

Then I could happily run Notepad++ as a regular user, and then I could drag & drop or use the ever-handy context menu again, from non-admin-mode explorer into non-admin-mode Notepad++.

I hope this helps you in some way.

share|improve this answer
    
When I ran into this problem, this is the real answer that I was looking for. I don't know what happened, but NPP didn't get like this until the most recent update a couple of days ago. –  darkpbj May 30 at 14:56
add comment

Louis gave you the correct technical answer, here is workaround. You can start the Explorer with admin rights with a hack and now you should be able to drag & drop files.

share|improve this answer
add comment

Lower-integrity processes can't pass messages to higher level ones.

You'll find that this is the case for any elevated process since Windows Vista onward.

Processes run under certain security access tokens and integrity levels. Explorer runs under your user account's restricted token with a medium integrity level, and when you elevate a process by running as administrator, it will use a different, unrestricted security token with a high integrity level.

Part of the security overhaul that came with Vista was User Interface Privilege Isolation, which prevents lower level processes from sending messages to higher level ones (because the messages may be malicious, as in the case of shatter attacks).

So in this case, Windows won't allow Explorer to send the drag and drop message to Notepad++ (it actually returns "success" but drops the message).

For more detailed information about access tokens, integrity levels and UIPI, see Windows Integrity Mechanism Design.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.