WorkbookOpenAsk_ANmar

Asks user to browse to a file and return full path and file name if they do, otherwise returns blank.
If StartingFolder is ignored, it will use FixPath to return folder of current workbook.
ExtFilters had an example of multiple filters in drop-down.

Function WorkbookOpenAsk_ANmar(Optional StartingFolder = "This", Optional ExtFilters = "All Excel files, *.xls?,All files, *.*")
 ' Asks for a file, then return null if canceled, or full file name and path if selected
 If StartingFolder = "This" Then StartingFolder = FixPath()
 ChDir StartingFolder
 Rett = Application.GetOpenFilename(ExtFilters)
 If Rett = "False" Then Rett = ""
 WorkbookOpenAsk_ANmar = Rett
End Function

Optional StartingFolder, Optional ExtFilters

Views 344 Downloads 151

'FixPath()', 'Workbook', 'open', 'GetOpenFilename', 'ask user', 'browse', 'select file', 'folder', 'GetSaveAsFileName'

ANmarAmdeen
324
Attachments
File System VBA-Excel
Revisions

v1.0

Needs