Results 1 to 4 of 4

Thread: Directory Browser?

  1. #1

    Thread Starter
    Lively Member malb's Avatar
    Join Date
    Feb 2005
    Location
    England
    Posts
    88

    Directory Browser?

    Is there a directory browser control similar to the file browser control? Ive been used to using the commonDialog control for chosing a file for save/open but is there a controll that lets the user simply puick a directory and click ok?

    Thanks Ghaz
    You fear me because I'm different, i pitty you because your all the same.

  2. #2
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: Directory Browser?

    Not a control, but a piece of code

  3. #3
    VB Addict Pradeep1210's Avatar
    Join Date
    Apr 2004
    Location
    Inside the CPU...
    Posts
    6,614

    Re: Directory Browser?

    VB Code:
    1. 'Make a reference to Microsoft Shell Controls and Automation
    2. Dim sh As New Shell32.Shell
    3. Dim str1 As Shell32.Folder2
    4.  
    5. Set str1 = sh.BrowseForFolder(Me.hWnd, "Select a Folder", 0, ssfDRIVES)
    6.  
    7. If Not str1 Is Nothing Then
    8.  MsgBox str1.Self.Path
    9. End If
    Pradeep, Microsoft MVP (Visual Basic)
    Please appreciate posts that have helped you by clicking icon on the left of the post.
    "A problem well stated is a problem half solved." — Charles F. Kettering

    Read articles on My Blog101 LINQ SamplesJSON ValidatorXML Schema Validator"How Do I" videos on MSDNVB.NET and C# ComparisonGood Coding PracticesVBForums Reputation SaverString EnumSuper Simple Tetris Game


    (2010-2013)
    NB: I do not answer coding questions via PM. If you want my help, then make a post and PM me it's link. If I can help, trust me I will...

  4. #4

    Thread Starter
    Lively Member malb's Avatar
    Join Date
    Feb 2005
    Location
    England
    Posts
    88

    Re: Directory Browser?

    thats fab, works great. thanks alot to you both
    You fear me because I'm different, i pitty you because your all the same.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width