Description
Unregisters a type previously registered with either RegisterType or RegisterInterfaceClassFactory.
-
Return Type
-
A Long value.
The remaining references on the specified type. This value will be -1 if the specified type is illegal for unregistering (out-of-range, already been unregistered or is a built-in type). Otherwise it will be the number of object and derived type references remaining on the type; this will be zero if the type is sucessfully unregistered.
-
Syntax
-
object.UnregisterType (varTypeNameOrEnum)
The UnregisterType Method syntax has these parts:
|
| object | An expression evaluating to an object of type McObjects. |
| varTypeNameOrEnum | Required. A Variant value. The type name or type enum to unregister.
|
Remarks
The predefined types cannot be unregistered and a type for which any objects of that type still exist cannot be unregistered. Similarly, a type which is being used as the base type for some other registered type cannot be unregistered.
If the varTypeNameOrEnum is given as a name, that type name must be within the scope of the current default Namespace, unless the actual namespace is supplied via the :: syntax.