The Scriptor component makes it possible to insert code modules into your pipeline. These modules are written using either the Microsoft® Visual Basic® Scripting Edition (VBScript) or JavaScript. From within a Scriptor component, you can access the OrderForm, pipe context information, create other objects, and even execute other pipelines. In addition, because the Scriptor component supports configuration parameters, the Scriptor component provides perhaps the easiest way to write custom components for the order processing pipeline (OPP).
When you add a Scriptor component to your pipeline, you configure the component using the Scriptor component's property page.
The Scripting Engine setting identifies the scripting engine you want to use to process the script. You can select any scripting engine installed on your computer.
Next, you specify whether you want the Scriptor component to execute an Internal or an External script. An Internal script is one in which the text of the script is stored in the Scriptor component itself. For example, if you select Internal, and then click Edit, the Scriptor component displays a Script Editing window that you use to write your script.
An External script is one that resides in a file on your hard disk. If you use the External script option, click the Browse button to locate the file in which the script is stored.
In the Config box, type the parameters and values that you want to pass to the script that you write. The ability to pass configuration parameters to the Scriptor component represents one of its most valuable features, because it allows you to set persistent property values on the Scriptor component, just as you would on any other component in the OPP.
Configuration parameters must be written using the name=value form. For example:
tax=1.35;shipping=2.00
The values of these parameters can be accessed by your script.