Skip to content

Instantly share code, notes, and snippets.

@thoriqmacto
Created October 28, 2014 09:33
Show Gist options
  • Save thoriqmacto/b5002dd9a51aae64eac4 to your computer and use it in GitHub Desktop.
Save thoriqmacto/b5002dd9a51aae64eac4 to your computer and use it in GitHub Desktop.
This routine is to show open file dialog and get the path of the file.
Sub browseFile()
Dim desPathName As Variant
desPathName = Application.GetOpenFilename(FileFilter:="Excel Files (*.xls*), *.xls*", Title:="Please select a file")
Range("D8").Value = desPathName
End Sub
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment