FolderBrowserDialogbox
I have a combobox which displays the list of drives in my computer. I want the folderbrowserdialogbox to show me the folder structer in the same form of the selected drive. let me know if anyone can help me
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
vijay172 reputationPosted Feb 22, 2011, 1:52 AM EST
if you want to select a file from the drive means you can use openfileDialog,BY using the u can select a any file, you can also apply filter by the selection..........http://vbdotnetaddict.blogspot.com
Raghavendra Shetty13 reputationPosted Feb 22, 2011, 4:01 AM EST
FroglegRank #1,020 · 1.9K reputationPosted Feb 22, 2011, 11:37 AM EST
FolderBrowserDialog1.SelectedPath - which will highlght your selected folder
FolderBrowserDialog1.RootFolder - which will open the dialog at any of default directories - which as far as I know you can't add to or change
My advice is create your own treeview, which can display the directories as you want
Hirendra SisodiyaRank #258 · 9.8K reputationPosted Feb 27, 2011, 12:31 AM EST
you want to use dialogbox for showing content of drive than you can show FolderBrowserDialogBox as popup box and set the selected path to drive path or if you want to show content of selected driveon form then you can use treeview.you can bind treeview with the help of IO.DirectoryInfo(filePath) class and its GetDirectories() method.
thanks