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

How implement a Browse button in macro for excel

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
I would like to implement a button with Browse funtion, does any boddy knows how to do it.
 
What did you want to browse?

If you want to browse for files, try using the following method to return a file:
Application.GetOpenFilename(FileFilter,FilterIndex,WindowTitle,ButtonText,MultiSelect)

Be wary of what the function returns.
If the user clicks the "Cancel" button, it returns a boolean value of False.
If the user clicks "OK", it returns a string variable.
If the user clicks "OK" and MultiSelect is True, it returns a string array.

Make sure you trap appropriately (I usually check the data type of what was returned with Information.VarType ...)

If you don't wish to browse files, what do you wish to browse?

Hope this helps,
Pete
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top