Results 1 to 3 of 3

Thread: show current folder in folder browser?

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Nov 2004
    Posts
    362

    show current folder in folder browser?

    Hi,

    I have a program load the saved folder (from last use) into a textbox, now, user click browse button, it launch the folder browse dialog, I can use selectedpath to set selected folder, but most of time, the folder is deep in the c:\, so, the folder browser dialog window does not show it, user has to scroll down to find it.

    is there a way to automatically show the selected folder in the view?

    if this can not be done in default folder browser dialog, is there an existing class/control can do this? or, have to write a tree view from scratch (including adding new folder,....) which is really what I want to avoid.



    thanks

  2. #2
    VB For Fun Edgemeal's Avatar
    Join Date
    Sep 2006
    Location
    WindowFromPoint
    Posts
    4,255

    Re: show current folder in folder browser?

    Quote Originally Posted by FlyingBear View Post
    is there a way to automatically show the selected folder in the view?
    I don't see that happening here (VB10/WinXP), when the dialog opens the .SelectedPath folder is near the bottom of the dialog, no need to scroll down.

    Code:
    Using fbd As New FolderBrowserDialog
        With fbd
            .SelectedPath = "C:\WINDOWS\system32\Microsoft"  ' < deep sub folder
            .Description = "Select Folder"
            If .ShowDialog = DialogResult.OK Then
                TextBox1.Text = (.SelectedPath)
            End If
        End With
    End Using

  3. #3

    Thread Starter
    Hyperactive Member
    Join Date
    Nov 2004
    Posts
    362

    Re: show current folder in folder browser?

    thanks. I'm using win7 64bits, tried on many machines, the same, the selected path is selected, but may not in the tree view. have to scroll down.

    thanks again.

    bear

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