Function GetFolder() As String
Dim dlgOpen As FileDialog
Set dlgOpen = Application.FileDialog(msoFileDialogOpen)
With dlgOpen
.AllowMultiSelect = False
.Show
End With
If dlgOpen.SelectedItems.Count > 0 Then
GetFolder = dlgOpen.SelectedItems(1)
Else
GetFolder = ""
End If
Set dlgOpen = Nothing
End Function