Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Shaun E on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Need help in creating a folder brwose list

Status
Not open for further replies.

siulong2002

Programmer
Jan 15, 2003
38
GB
Can anyone help me or point me in the right direction for creating a folder browse list for the application I've created. Basically i want people to be able to click on a button, then it opens up the folder list in another window.
Any help would be much appreciated.

Thanks

Wayne
 
On a new form, place a dirListBox. Set the path to C: and away you go. When the user is finished, simply return the path the user has chosen.

I think - if memory serves - the DirListBox is in Components - Microsoft Windows Controls 6.0.

However, if you want the user to be able to find a specific type of file, use the common dialog controls - open.

Good luck

BB
 
Thank you for the Tip. I should've said In my earlier post that I'm a new programmer and really need to be shown the code aswell.
 
Add the component Microsoft Windows Controls 6.0, by going to the component mwnu under Project.

Then, add a dirListBox which will now be in the toolbox.

In the form load sub, place:

Dir1.path= "c:\"

in the submit button on this form, place:

msgbox Dir1.path

Now you can use the dir1.path for any file operation you like.

BB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top