0

Run VBScript from Notepad++

Notepad++ is brilliant in its infinite capacity for customisation, I recently found out that it can be taught to run VBScript files straight from the editor via keyboard shortcut – no more saving, navigating to the folder to run the file and then back to Notepad++ to edit again! to do this simply

 

  1. Find the shortcut.xml file. Generally this is somewhere like:
    "C:\Users\Username\AppData\Roaming\Notepad++"
  2. Open it up and find theĀ <UserDefinedCommands> section
  3. Add in the line
    <Command name="Wscript" Ctrl="yes" Alt="no" Shift="no" Key="116">c:\WINDOWS\system32\wscript.exe &quot;$(FULL_CURRENT_PATH)&quot;</Command>
  4. Close all open instances of Notepad++

 

Voila, now whilst you’re in Notepad++ you can execute the currently open file by hitting Ctrl+F5 although you can change this mapping by going to “Run”>”Modify shortcut/Delete command”.

Note: This passes the path of the currently open file so you’ll need to save your file before running it to reflect changes

JBaker

Joi is an IT Development Analyst working in London and a consummate technophile. Whilst he isn't coding he can be found reacquainting himself with his guitars, spinning poi, looking for climbing walls or chasing the latest shiny thing to cross his field of vision.

Leave a Reply

Your email address will not be published. Required fields are marked *