Equinox Online Help - Language Reference - A to Z

Home

External Object

Applies to
SyntaxExternal Object "ObjectName" [Version] InternalObjectName
Action[Statement] Declares an ActiveX object and its interface.
ScopeUsable anywhere.
NotesThis statement declares a ActiveX object or one of its access methods, so that you can use it in Equinox. It is generated automatically by Equinox in the Public Procedure editor, via the menu option Add External Object. See the section on ActiveX for more details. The format is very similar to the External statement, which shares many of its parameters. Refer to that statement for more details about parameters not described. The first form describes an object, and the second form includes the description of an access method. The ObjectName parameter contains the name of the object as known to the operating system, inside quotes. Version is a number in the format Major dot Minor which defaults to 1.0, the version of the object interface required. The dot Minor is optional, and defaults to zero. InternalObjectName is the unique name by which Equinox will know the object. It can be any valid Equinox identifier. CallType must be one of the three keywords PropertyGet, PropertyPut or Method. CallName is the name of the method or property as known to the object, inside quotes. InternalCallName is the name of the method or property as known to Equinox, which can be any valid Equinox identifier. The MustReturn keyword may be substituted for Returns.
CategoryWindows and DLLs
See Also  
Example

The following example shows how Equinox might define an object. Features which Equinox cannot support are included, but commented out. The define statement is used to make the object definition more readable.

define Variant long
define Objdef Public External Object "Acme.ServiceManager" 3.11 AcmeService
define DECLM Objdef Method
define DECLG Objdef PropertyGet
define DECLP Objdef PropertyPut

| DECLM QueryInterface ptr , ptr ptr Void
DECLM AddRef returns Long
DECLM Release returns Long
DECLM EnumServices returns Variant
DECLM CreateService Ptr String, Ptr String, Long, Variant returns Variant
DECLM DeleteService Ptr String returns Long

DECLG Name returns Ptr String
DECLP Display Int

| Variable SecurityMode