Accelerator Keys

These are the keys that people without mice love. When developing a dialog, it is good practice to include them. To add accelerator keys open a control's format object dialog. Right-click on the control, select Format Object, and add the key in the Control tab of the dialog. Trick: To set the accelerator key for an edit box, create some fixed text in the dialog called a label control. Put the label next to the edit box and set an accelerator key for the label. Then, place the edit box immediately after the label in the tab order. When the user tabs through the controls while the dialog is running, Excel automatically passes the focus to the next control in the tab order that can accept the focus. This will be the edit box (labels can't accept focus, but they can have accelerator keys!)