BrowseFolder ?

  • Thread starter Thread starter sunflower
  • Start date Start date
S

sunflower

I am looking for a way to have a command button with an onclick code to
Browse Folders...
I need the full path of a file location to be automatically inserted in
a text box after selecting

any help is greatly appreciated
 
I am very new to this coding stuff...
So I apologize now for my ignorance…

I got the Folder Dialog box to work
now my next question is…
After the user selects the path from the Folder Dialog box
how do I get the path to the textbox?
 
You probably have a command button on your form, so the user clicks the
button to browse for the folder. Use the Click event procedure of the
command button to put the return value into your text box:

Private Sub cmdBrowse_Click()
Dim strFolder As String
strFolder = BrowseFolder("Gimme a folder")
If Len(strFolder) > 0 Then
Me.[NameOfYourTextBoxHere] = strFolder
End If
End Sub
 
Back
Top