PRB: Can't Use ActiveForm to Reference Data Control in VB 3.0Last reviewed: June 21, 1995Article ID: Q101252 |
The information in this article applies to:
- Microsoft Visual Basic programming system for Windows, version 3.0
SYMPTOMSUsing the ActiveForm Property of the Screen control or an MDI Parent form to reference a Data control causes a "Type Mismatch" error in Visual Basic.
CAUSEThis behavior is by design. This is not a bug in Visual Basic. The Visual Basic environment does not know in advance that the Active form will actually contain a Data control, so it generates a "Type mismatch" error.
WORKAROUNDTo avoid the error message, use global objects to reference the local controls. The "More Information" section below demonstrates one method for doing this.
STATUSThis behavior is by design.
MORE INFORMATION
Steps to Correct ProblemThis example shows how to correct the problem. First, create the problem by following the steps listed in "Steps to Reproduce Problem." Then correct the problem with these steps:
Steps to Reproduce Problem
|
Additional reference words: 3.00 errmsg
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |