:INCLUDE

Script Statement: Integrates an Include object into a script.

Syntax

:INC[LUDE] Include Object [OldString = NewString][,NOFOUND=IGNORE][,EXT_REPORT=OFF]

Syntax

Description/Format

Include Object

The name of the Include object that should be integrated

Enter the complete name of the Include object. Script variables are not allowed.

OldString

The string of the Include object's script that should be replaced by NewString
Format: script literal

NewString

The string that should replace OldString from the script of the Include object.
Format: script literal

Maximum 50 characters

NOFOUND=IGNORE

No error occurs when the specified Include object canot be found.

EXT_REPORT=OFF

Include object contents are not logged in extended reports. A comment line is output instead.

Comments

Many objects use identical processing steps in their scripts. Because of Include objects, they do not have to be written and maintained in every single script. Include objects contain often used script parts.

Use the statement :INC to address an Include object from a different object. Whenever an object containing this script statement is activated, the Include object's script is integrated.

OldString and NewString are optional parameters. They can be used to replace an Include object's string by another one. Replacements are only valid for the current generation and do not change the Include object itself.

Examples

This example shows how an Include object is integrated. The string "$MM." specified in the Include object obtains the new name "$MMTEST".

:INC MM.FILEASSIGNMENTS "$MM." = "$MMTEST."  

In the next example, a user Include is called. No error occurs if it does not exist.

:INCLUDE HEADER.WINDOWS.USER.HEAD ,NOFOUND=IGNORE

Logging the contents of the Include object to extended reports is suppressed in the example shown below. 

:INC MM.FILEASSIGNMENTS ,EXT_REPORT=OFF

Viewing :INCLUDE Statements in the Script Editor

You can use the script editor to display and edit the contents of your Include objects.

You expand the Include object in a read-only dialog by clicking the plus symbol on the left edge.

Resolving :INCLUDE Statements

To copy the contents from the Include object to the script editor, click Resolve Include.

A comment will denote that the code came from the contents of the Include object. Any future changes to the Include object will have no effect here. Any changes you make in the script editor will have no effect on the Include object.

See also:

Script element Description

:INC_SCRIPT

Integrates a script into another script of the same object

Script Elements - Script Structure and Processing

About Scripts
Script Elements - Alphabetical Listing

Script Elements - Ordered by function