views:

226

answers:

2

I'm using an old version of Visual Studio that provides only the 'interactive' method for setting tab stops. Is there anyway to clear all the tab stops before setting them? Or anyway to exclude a given control from having a tab stop?

Added 10-sept-2009 Part of my problem was confusing tab stop order and tab stops. I naively assumed setting tab stop order, set a tab stop hence much confusion. Thanks for pointing out that tab stops are set in the property box.

+3  A: 

You are not clear about your specific VS version, but as far as I remember (back to VC6) you automatically assign the tab order if you simply click once on each control in your desired order. There is usually no need to reset them beforehand.

This hint from a VC6 tutorial might be helpful:

To adjust the tab order of your controls, you can choose the Tab Order command from the Layout menu and click the controls in the order that you want them to be tabbed. If you have a complicated dialog box and only want to change the tab order of a few controls, you can take a little shortcut by holding the Ctrl key down and selecting the last control that tabs properly before selecting the controls that tab incorrectly. Clicking an empty spot in the dialog box, or pressing Enter, will exit the tab order mode.

To prevent a control from being reached using the Tab key, clear the Tab stop checkbox on the control's property page.

If you want to change the tab behaviour programmatically, look for the WS_TABSTOP windows style.

Frank Bollack
+1  A: 

Open the dialog whose tab order you want to change. Press Ctrl + D. On the dialog you will see numbers next to each control which indicate the tab order for that control. Click the controls in the order you want the tab order to go.

rahul