ArcPad acts as an active script host for your JScript, VBScript code or Python code. In order to allow all the scripts that reside in various files to interact with ArcPad and not interfere with each other, the host creates several instances of scripting engines - one for the Application object, one for each Layer object present, and one for each Applet object present. Each of these script engine instances is known as a scripting space.
- Any scripts present in the default configuration file (ArcPad.apx) or its associated .js/.vbs file are available to the Application object's scripting space.
- Any scripts present in a layer's layer definition, .apl file or associated .js/.vbs file are available to that Layer object's scripting space.
- Any scripts present in an applet's .apa file or associated .js/.vbs file are available to that Applet object's scripting space.
Therefore, for example, script code present in the default configuration file is not available to scripts present in a particular layer's APL file. If a script needs to access another script that is present in a different scripting space, use the Execute or Evaluate methods of the Applet, Application, or Layer object, as appropriate, to accomplish this.