PRB: Access Key Causes Different Event Order than Mouse Click (74905)
The information in this article applies to:
- Microsoft Visual Basic Control Creation Edition for Windows 5.0
- Microsoft Visual Basic Learning Edition for Windows 5.0
- Microsoft Visual Basic Professional Edition for Windows 5.0
- Microsoft Visual Basic Enterprise Edition for Windows 5.0
- Microsoft Visual Basic Standard Edition for Windows 2.0
- Microsoft Visual Basic Standard Edition for Windows 3.0
- Microsoft Visual Basic Standard Edition for Windows 4.0
- Microsoft Visual Basic Professional Edition for Windows 2.0
- Microsoft Visual Basic Professional Edition for Windows 3.0
- Microsoft Visual Basic Professional Edition for Windows 4.0
- Microsoft Visual Basic Standard Edition for Windows 1.0
- Microsoft Visual Basic for MS-DOS
This article was previously published under Q74905 SYMPTOMS In Visual Basic, events may be generated in a different
order if you choose a control (such as a button, a check box, or an option box)
using an access key rather than with the mouse. The events that occur in a
different order are Click, LostFocus, and GotFocus. RESOLUTION By inserting the DoEvents statement as the very first
statement in the Click event handler, you can cause the LostFocus and GotFocus
events to be handled before the body of the Click event handler. STATUS This behavior is by design. It is not a bug in Visual
Basic.
Modification Type: | Minor | Last Reviewed: | 8/11/2006 |
---|
Keywords: | kbprb KB74905 |
---|
|