IsComObjectCreated - cComDocumentObject

Tests to see if a COM object exists by getting the value of IsComObjectCreated

Type: Function

Return Data Type: Boolean

Parameters: None

Return Value

This function returns True, if the COM object has been created indicating that it is safe to access its interface.


Syntax
Function IsComObjectCreated Returns Boolean

Call: Get IsComObjectCreated to BooleanVariable


Description

You can test to see if a COM object exists by getting the value of IsComObjectCreated.

This is analogous to testing if the pvComObject property is Not Null (created), or Null (released).

Testing IsComObjectCreated is crucial to writing error free COM applications. You should test this value before executing any code that accesses a COM object's interface methods or properties. The exception to this rule is when you access a COM object inside an OnCreate event handler.

See Also

CreateComObject