Object Variables

In Scripter, object variables contain references to ActiveX objects. Creating the program Application object is an example of declaring an object variable:

Dim GrapherApp As Object

Set GrapherApp = CreateObject("Grapher.Application")

In this example, a DIM statement declares that the variable named GrapherApp holds a reference to an object. The built-in CreateObject function returns a reference to a Grapher Application object, and the SET statement assigns this object reference to the GrapherApp variable. Unlike variables of other types, which can be assigned new values simply with an equal sign ( = ), object variables must be assigned values with a SET statement.

See Also

Variables

Array Variables

User-Defined Types

Global Variables

Coordinate Arrays

Scripter BASIC Language

Object Hierarchy

Object List