|
Using Includes
VBScript does not natively support "Includes".
However, SystemScripter does. With
Includes, you can create your own script
libraries, recycle code and keep your
scripts easy to read and maintain.
Here's how it works:
First, create your
script library. A script library is a
simple script that defines one or more
procedures or functions. For simplicity,
let's assume you created the following
script and saved it as c:\library1.vbs:

Whenever you need a random number, you
would either have to copy and paste your
function into your script, or you use
includes. For that, you just put this
statement into your script:

SystemScripter
automatically generates the Include
procedure that is necessary to read in
your external script code. But that's
not all. SystemScripter also discovers
all procedures and methods in your
script library and supports them. So
when you enter GetRandom and press TAB,
the function name is auto-completed, and
SystemScripter shows the correct Info
Tooltip:
|
|

|
|
You can use as many external script
libraries as you like. Just include them
all using the new Include procedure
SystemScripter added to your script. And
since it is plain VBScript, your include
mechanism works everywhere.
SystemScripter helped you create the
includes, but the result is a standard
script.
You can even
debug includes.
|