The information in this article applies to:
SYMPTOMS
When using a COM component from Visual Basic, you may not receive a compile-
time error if you accidentally misspell a property or method name. Instead,
Visual Basic will generate the following error at run-time:
CAUSE
This situation occurs when the object being referenced supports a dual or
dispinterface, and therefore can be late-bound. If the component designer
did not mark the interface as being "nonextensible," then Visual Basic
cannot determine if the misspelled method/property name is misspelled, or
if it is a new method or property added to the interface at a later time.
Consequently, Visual Basic does not raise an error at compile-time, but
rather checks at run-time whether the component supports a method/property
by that name. The run-time error occurs if the object does not have the
named method/property.
STATUSThis behavior is by design. MORE INFORMATION
If you use Visual C++ to write your COM components, the default IDL files
generated by the IDE do not contain the "nonextensible" keyword. COM
components created in Visual Basic always contain this keyword.
Additional query words:
kbDSupport kbDSD kbVBp kbVBp500 kbVBp600 kbCtrlCreate kbActiveX kbCOMt
Keywords : kbGrpVB |
Last Reviewed: January 5, 2000 © 2000 Microsoft Corporation. All rights reserved. Terms of Use. |