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 Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Need assistance writing a browse control

Status
Not open for further replies.

moreice

Programmer
Sep 16, 2002
3
US
I am attempting to create a command button in an access form that will browse a workstation for a path to a filename and populate a field in the form with that path. I would hope there is a nice and easy ready made Microsoft function for this, however i have not been able to find it... If anyone out there can help me with this, i would greatly appreciate it!

Thanks in Advance,
Ice
 
Application.ScreenUpdating = False
Filter = "MDE files (*.mde), *.mde"
Caption = "Select a File"
Dim SelectedFile As String
thePath = ** set a default path **
If thePath <> &quot;&quot; Then
If Dir(thePath, vbDirectory) <> &quot;&quot; Then
ChDir thePath
End If
End If

FileSelected = Application.GetOpenFilename(Filter, , Caption, , False)
 
Thanks for your fast response... I was able to do a keyword search on my issue after i joined the site and i found some very useful stuff... I will also tryout the code given above...

Thanks again,
ice
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top