Chapter 16. Windows Script Components

In this chapter, you examine Windows Script Components including their structure and how to create and register them. Later in the chapter, you'll see how to use classes in your components. If you are used to using XML, then the structure of the script here will be familiar to you and that will be a huge advantage. If not, work carefully through the examples and all will become clear!

What Are Windows Script Components?

Windows Script Components are interpreted COM components (they have to be interpreted because VBScript and all other scripting languages are interpreted). Structurally, they are XML-based files that contain script code. Within the files themselves you can use VBScript, JScript, Python, PScript, PERLScript, or any other scripting language. As always, the focus in this chapter is on using VBScript (for obvious reasons), but it is possible to use the scripting language of your choice.

The script components are interpreted by the Script Component Runtime, which exposes the internal properties and methods, fires the events, and makes the component look like a compiled COM component to the calling application. You'll look at the Script Component Runtime in more detail in the next section. Script components are full COM components, and have the ability to call others COM components. They also have some interfaces built into the Active Server Pages library and Internet Explorer DHTML behaviors that make it very easy to build these components ...

Get VBScript Programmer's Reference, Third Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.