All Manuals > LispWorks COM/Automation User Guide and Reference Manual > 4 Automation Reference Entries

NextPrevUpTopContentsIndex

get-active-object

Function
Summary

Looks for a registered running instance of a coclass.

Signature

get-active-object &key clsid progid riid errorp => interface-ptr

Arguments

clsid

A string or a refguid giving a CLSID to create.

progid

A string giving a ProgID to create.

riid

An optional refiid giving the COM interface name to return.

errorp

A boolean. The default is t.

Values

interface-ptr

A COM interface pointer for riid.

Description

Looks for a registered running instance of a coclass in the system Running Object Table and returns its riid interface pointer if any. If riid is nil, then i-unknown is used.

The coclass can be specified directly by using the clsid argument or indirectly using the progid argument, which will locate the CLSID from the registry.

If errorp is true, then an error is signaled if no instances are running. Otherwise nil is returned if no instances are running.

Example
(get-active-object :progid "Excel.Application"
                   :riid 'i-dispatch)
See also

get-object


LispWorks COM/Automation User Guide and Reference Manual - 23 Mar 2017

NextPrevUpTopContentsIndex