Important: The information in this document is obsolete and should not be used for new development.
Executing Scripts
MacApp provides theTExecuteScriptCommand
class to execute a script. You initialize a command object of this type by calling theIExecuteScriptCommand
method. You pass anOSAID
value specifying the script to be executed, anOSAID
value specifying the script context, and aComponentInstance
value specifying the scripting component, along with standard command information such as the context and command number.The
DoIt
method of theTExecuteScriptCommand
object executes the script that was specified in theIExecuteScriptCommand
method. For sample code that demonstrates how to execute a script withTExecuteScriptCommand
, see theTMenuBehavior
class in the DemoText sample application distributed with MacApp.