120 Part I Getting Started with Microsoft Visual Basic 2010
To Do This
Use a standard dialog
box in your programAdd one of the eight standard dialog box controls to your form, and
then customize it with property settings and program code. Dialog
box controls are located on the Dialogs and Printing Toolbox tabs.
Display an Open
dialog boxAdd the OpenFileDialog control to your form. Display the dialog box
with the ShowDialog method. The FileName property contains the
name of the file selected.
Display a Color
dialog boxAdd the ColorDialog control to your form. Display the dialog box with
the ShowDialog method. The Color property contains the color the
user selected.