Using Dialog Boxes

When you use a custom dialog box in your application, you normally write VBA code that does the following:

1 Initializes the UserForm controls. For example, you may write code that sets the default values for the controls.

i Displays the dialog box by using the UserForm object's Show method.

1 Writes event-handler procedures for the various controls.

i Validates the information provided by the user (if the user did not cancel the dialog box). This step is optional.

i Takes some action with the information provided by the user (if the information is valid).

0 0

Post a comment