Represents a common dialog box that allows the user to choose a folder.


This class provides a way to prompt the user to browse, create, and eventually select a folder. Use this class when you only want to allow the user to select folders, not files. Browsing of the folders is done through a tree control. Only folders from the file system can be selected. Virtual folders cannot.

Typically, after creating a new FolderBrowserDialog, you set the RootFolder to the location from which to start browsing. Optionally, you can set the SelectedPath to an absolute path of a subfolder of RootFolder that will initially be selected. You can also optionally set the Description property to provide additional instructions to the user. Finally, call the ShowDialog method to display the dialog box to the user. When the dialog box is closed and the dialog result from ShowDialog is OK, the SelectedPath will be a string containing the path to the selected folder.

You can use the ShowNewFolderButton property to control if the user is able to create new folders via the New Folder button.

FolderBrowserDialog is a modal dialog box; therefore, when shown, it blocks the rest of the script until the user has chosen a folder. When a dialog box is displayed modally, no input (keyboard or mouse click) can occur except to objects on the dialog box.

The CHM file was converted to HTML by chm2web software.