Notepad++ automatically adds a shell shortcut so that when you\'re in Windows Explorer, you can right-click on a file and select \"edit with Notepad++\". How can I do the same w
I want to add to polyglot's answer above -- the AutoHotkey shortcut he mentions is very handy, but the code is incomplete: the GetText() function was written by somebody on the AutoHotkey forum (http://www.autohotkey.com/forum/viewtopic.php?p=279576#279576), and it is:
GetText(ByRef MyText = "")
{
SavedClip := ClipboardAll
Clipboard =
Send ^c
ClipWait 0.1
If ERRORLEVEL
{
Clipboard := SavedClip
MyText =
ERRORLEVEL := 1
Return
}
MyText := Clipboard
Clipboard := SavedClip
Return MyText
}
;to test:
#k::
GetText(FileName)
msgbox clipboard=%FileName%
return
Note that ClipWait delay might need to be modified: I had to set it to 2!