Msg Box customisation

A MsgBox function can be customised in many ways, as the example in Figure 3.7 shows. A number of examples follow that illustrate customisation. The first example provides a meaningful title "To whom it may concern" in the Title bar by replacing the default "Microsoft Excel" title. This example also uses an indicator inside the dialog box of the type of data being displayed - in this case "i" for information. This variation is produced by including two optional arguments in the MsgBox statment as follows and produces the output shown in 3.7:

MsgBox "Hello!", vblnformation, "To whom it may concern"

Displays this title in Titlebar

Figure 3.7 The MsgBox function including title display

Displays this title in Titlebar

Figure 3.7 The MsgBox function including title display

0 0

Post a comment