• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

9. Scripting and Automation > 9.1. Building a Script with VBScript

Building a Script with VBScript

A script is simply a list of commands that are placed one after another and stored in a text file. Script commands are like building blocks: the more commands and programming techniques you learn, the broader your palette will be for making useful scripts. Some of the simpler building blocks will be used in this section of the chapter to illustrate the way scripts are built. Advanced users may prefer to skip to subsequent sections, which cover more advanced topics.

To run a script, just double-click on the script file icon; you’ll probably never need to run the Scripting Host program (wscript.exe) directly.

Tip

There are actually two script interpreters (engines) included with Windows XP. WScript.exe is a native Windows interpreter and is used in most cases. CScript.exe is a console interpreter, which is used when you want the script output to be sent to the console (Command Prompt). You can use CScript.exe at any time by right-clicking a script file and selecting Open with Command Prompt.


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint