newObjects-logo.gif (1024 bytes) ScriptAggregate reference
WhereIsDefined method

Returns boolean result indicating if the name passed as parameter corresponds to a routine or variable in the running script.

variable = object.WhereIsDefined(name [, type])

variable String True if the name exist, False if not
object ScriptAggregate Previously created ScriptAggregate object
name String The name to check 
type number 1 - return name (language name)
0 - return engine index (default)

Remarks:

WhereIsDefined method gives you a chance to see if a certain element is defined in the script. It returns the name or index of the script language in which the routine/variable is defined. This value can be used in subsequent call(s) of the method (or accessing variable) through the script property.

id = aggreg.WhereIsDefined("MyFunction")
MyVariable = aggreg.script(id).MyFunction(param1,param2)

Applies to:

ScriptAggregate object

See also:

newObjects Copyright newObjects 2001-2005