ControlBox Property False Disables Focus with Keys in Menus

ID Number: Q76556

1.00

WINDOWS

Summary:

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.

Microsoft has confirmed this to be a problem with Windows version 3.0.

We are researching this problem and will post new information here as

it becomes available.

This information applies to Microsoft Windows version 3.0 and to

Microsoft Visual Basic programming system version 1.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.

More Information:

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 reference words: 1.00 3.00