Dialog Box Checklist

I wrap up this chapter with a checklist for use when creating dialog boxes:

□ Are the controls aligned with each other?

□ Are similar controls the same size?

□ Are controls evenly spaced?

□ Does the dialog box have an appropriate caption?

□ Is the dialog box overwhelming? If so, you may want to use a series of dialog boxes.

□ Can the user access every control with an accelerator key?

□ Are any accelerator keys duplicated?

□ Are the controls grouped logically, by function?

□ Is the tab order set correctly? The user should be able to tab through the dialog box and access the controls sequentially.

□ If you plan to store the dialog box in an add-in (which I discuss in Chapter 22), did you test it thoroughly after creating the add-in? Remember that an add-in is never the active workbook.

□ Will your VBA code take appropriate action if the user cancels the dialog box or presses Esc?

□ Does the text contain any misspellings? Unfortunately, the Excel spell checker doesn't work with UserForms, so you're on your own when it comes to spelling.

□ Will your dialog box fit on the screen in the lowest resolution to be used (usually 800x600 mode)? In other words, if you develop your dialog box by using a high-resolution video mode, your dialog box may be too big to fit on a screen in lower resolution.

□ Do all TextBox controls have the appropriate validation setting?

□ Do all ScrollBars and SpinButtons allow valid values only?

□ Do all ListBoxes have their MultiSelect property set properly?

The best way to master custom dialog boxes is by creating dialog boxes — lots of them. Start simply and experiment with the controls and their properties. And don't forget about the Help system; it's your best source for details about every control and property.

0 0

Post a comment