devxlogo

The MB BrowseForFolder Control

The MB BrowseForFolder Control

If you want to show the “Browse for Folder” dialog in your own application, this is the tool for you. It enables you to change any dialog’s property, such as its caption, foreground color, font, TreeView styles (HotTracking, SingleClickExpand, LinesAtRoot and so on), a textbox to manually type the folder name, and a label control to display the currently selected folder. You can also decide to display folders only, folders and file, printers or the Internet neighborhood. The control exposes a set of events that let you know when the dialog is about to be displayed (so that you can select an initial folder) and when a user selects a folder, and you can cancel the standard dialog action. You can also learn everything about the item that is currently selected: its path and display name, its small and large icons, its description, the type of exe (if it is an executable file), all its attributes. If the user selected a folder, you can determine whether it is shared or has any subfolders. The package contains both the control and a class module, so that you can use all the functionality even if you don’t have a form to place the control on. There is also a FolderTree control, a special TreeView control that automatically shows the file system structure and all its item. You can use it to create an even more customized “Browse for folder” dialog or to add a file/folder browser into your own application. Get the source code.

devxblackblue

About Our Editorial Process

At DevX, we’re dedicated to tech entrepreneurship. Our team closely follows industry shifts, new products, AI breakthroughs, technology trends, and funding announcements. Articles undergo thorough editing to ensure accuracy and clarity, reflecting DevX’s style and supporting entrepreneurs in the tech sphere.

See our full editorial policy.

About Our Journalist