Microsoft KB Archive/76556

= FIX: ControlBox Property False Disables Focus w/ Keys in Menus =

Article ID: 76556

Article Last Modified on 1/8/2003

-

APPLIES TO


 * Microsoft Visual Basic 1.0 Standard Edition

-



This article was previously published under Q76556



SYMPTOMS
When the ControlBox property on a form is set to False, (disabling the Control Box), the ability to change focus within menus using the keyboard (such as by using the ARROW keys) is lost. This is because of a limitation of Windows; it is not a problem with Visual Basic.



STATUS
Microsoft has confirmed this to be a problem with Windows version 3.0. This problem was corrected in Microsoft Visual Basic version 3.0 for Windows.

This problem only applies to changing focus between menu items. The ARROW keys work correctly to change focus with other controls (for example, two command buttons), even with the ControlBox disabled.



Steps to Reproduce Problem

 * 1) Start Visual Basic.
 * 2) From the Window menu, choose Menu Design Window.
 * 3) Enter Test1 and Test2 as the caption and CtlName of two separate top level menu items. Choose the Done button to close the Menu Design window.
 * 4) From the Properties box, select ControlBox.
 * 5) From the Settings box, set the ControlBox property to False. (This removes the ControlBox from the form at run time.)
 * 6) Press F5 to run the application.

Notice that the mouse can be used to select either the Test1 or Test2 menu, but pressing the ALT key followed by the LEFT or RIGHT ARROW keys will not allow you to move between the menus. You will only be able to select the Test1 menu by pressing the ALT key.

Setting the ControlBox property to True will re-enable the LEFT/RIGHT ARROW keys to select menu items.

Additional query words: fixlist2.00 fixlist3.00 2.00 3.00

Keywords: kbbug kbfix KB76556

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.