Page 1 of 1

Tip on how to Run/Debug VBScript code from Textpad

Posted: Wed Jul 09, 2003 9:27 am
by helios
From the TextPad Menubar, choose: Configure / Preferences / Tools

Click “Add�, DOS Program

Enter “Run (CScript)� for the name

Click “Apply�



In the tree pane on the left, expand the Tools branch

Double click the “Run (CScsript)� entry you just created

Parameters = cscript $File

Initial folder = $FileDir



When using CScript, output from Msgbox and Wscript.Echo will be sent to the TextPad Command Results window.

To use WScript instead, use “WScript $File� as the parameter. Output will be shown a line at a time in Windows dialog boxes.

To debug, follow the same procedure, but append “//X� to the parameter. This will launch the script into the debugger (e.g. Microsoft Script Debugger)


Contributed by David Brown.

Re: Tip on how to Run/Debug VBScript code from Textpad

Posted: Sat Feb 14, 2004 4:18 pm
by Alex K. Angelopoulos
Minor erratum. The following is NOT true about MsgBox; MsgBox always calls an actual messagebox for display.
helios wrote: When using CScript, output from Msgbox and Wscript.Echo will be sent to the TextPad Command Results window.

Contributed by David Brown.