O
oitbso
Both the "GetOpenFilename" and the "Dialogs(xlDialogOpen)" methods as used below will allow you to select a file in a specific folder and then open it.. Is there an advantage of one method over the other, or a situation whereone method is preferred over the other?..Thanks, Ron
MyPath = "C:\test\*.csv"
ChDrive MyPath
ChDir MyPath
FileName = Application.GetOpenFilename
If FileName = "" Then
MsgBox "No File Selected"
End
End If
Workbooks.Open FileName:=FileName
-or-
Application.Dialogs(xlDialogOpen).Show "C:\test\*.csv"
MyPath = "C:\test\*.csv"
ChDrive MyPath
ChDir MyPath
FileName = Application.GetOpenFilename
If FileName = "" Then
MsgBox "No File Selected"
End
End If
Workbooks.Open FileName:=FileName
-or-
Application.Dialogs(xlDialogOpen).Show "C:\test\*.csv"