BUG: Option Button w/ Focus Selected When Click Form Caption (79602)
The information in this article applies to:
- Microsoft Visual Basic Standard Edition for Windows 2.0
- Microsoft Visual Basic Standard Edition for Windows 3.0
- Microsoft Visual Basic Professional Edition for Windows 2.0
- Microsoft Visual Basic Professional Edition for Windows 3.0
- Microsoft Visual Basic Standard Edition for Windows 1.0
This article was previously published under Q79602 SYMPTOMS
In Visual Basic, if you run a program that contains an option button
group, and one of the option buttons is not selected but has the
focus, that option button will be selected -- causing the option button
Click event -- when you select the form title bar, Minimize button,
Maximize button, control menu box, or form size handles. This is does
not occur with other Windows programs.
An option button Click event will also occur incorrectly on a form
Load event if the option button is the only control on the form or if
the option button's TabIndex property is set to 0. When the TabIndex
property is 0, the option button is the control that gets the focus,
causing a Click event for the option button. Putting another control
on the form and setting that control's TabIndex to 0 solves the problem.
STATUS
Microsoft has confirmed this to be a bug in the Microsoft products listed
at the beginning of this article. We are researching this problem and will
post new information here in the Microsoft Knowledge Base as it becomes
available.
Modification Type: | Major | Last Reviewed: | 12/12/2003 |
---|
Keywords: | kbbug KB79602 |
---|
|