PRB: No Events Generated When Msgbox ActiveLast reviewed: June 21, 1995Article ID: Q76557 |
The information in this article applies to:
- Standard and Professional Editions of Microsoft Visual Basic for Windows, versions 2.0 and 3.0
SYMPTOMSVisual Basic does not invoke the Paint event or any other event for controls or forms while a MsgBox or InputBox is active.
CAUSEThis behavior is by design. All events (including the timer control event) are disabled while a MsgBox is showing. The purpose is to block operations that could cause problems.
WORKAROUNDTo compensate for Paint events not firing, you can set the form AutoRedraw property to True and paint the form from the Form_Load event. To display a MsgBox-like dialog and allow all events to occur, you can:
STATUSThis behavior is by design.
MORE INFORMATION
Steps to Demonstrate Behavior
As String, ByVal lpCaption As String, ByVal wType As Integer) AsInteger
and the area previously occupied by the MsgBox is not updated.
|
Additional reference words: 2.00 3.00
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |