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

Add Browse Button to Form

Status
Not open for further replies.

tortelvis

IS-IT--Management
Feb 13, 2001
16
US
I'd like to add a functional "browse" button so the end user could browse for a file to input. The full path would be returned to an input box on the form.

Anybody know where to start?

Thanks,

Tort
 
Woa, lots to comprehend.

Were would this code go exactly?
In a Class Object maybe? or a Module?
The error I get is 'Cannot define a public user-defined type within an object module'

Where would it go?

Tort
 
OK....Got it to work. Now how do I pass the variable strInputFileName back to a box on my form?

Here is the call that grabs the file:
Dim strFilter As String
Dim strInputFileName As String

strFilter = ahtAddFilterItem(strFilter, "Excel Files (*.XLS)", "*.XLS")
strInputFileName = ahtCommonFileOpenSave( _
Filter:=strFilter, OpenFile:=True, _
DialogTitle:="Please select an input file...", _
Flags:=ahtOFN_HIDEREADONLY)

-Tort
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top