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

Chapter 12. Programming the Windows Script Host

Chapter 12. Programming the Windows Script Host

In This Chapter

In Appendix C, “Automating Windows XP with Batch Files,” you learn how to tame the command prompt by creating batch files—small, executable text files that run one or more commands. You’ll see that with a little ingenuity and a dash of guile, it’s possible to make batch files perform some interesting and useful tasks. Indeed, for many years, batch files were the only way to automate certain kinds of tasks. Unfortunately, the batch file world is relentlessly command-line–oriented. So, with the exception of being able to launch Windows programs, batch files remain ignorant of the larger Windows universe.

If you’re looking to automate a wider variety of tasks in Windows, you need to supplement your batch file knowledge with scripts that can deal with the Registry, shortcuts, files, and network drives, and that can even interact with Windows programs via Automation. The secret to these powerful scripts is the Windows Script Host (WSH). This chapter introduces you to the Windows Script Host, shows you how to execute scripts, and runs through the various elements in the Windows Script Host object model.

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