C
calebjill
I have some code to open all excel files in a folder, but it will only open
the files that are not hidden. Is there a way to open all the files
regardless of hidden status.
Here is the code.
Sub open_all_files()
Dim path As Variant
Dim excelfile As Variant
path = "c:/users/caleb/documents/commissions experiment/"
excelfile = Dir(path & "*.xls")
Do While excelfile <> ""
Workbooks.Open Filename:=path & excelfile
excelfile = Dir
Loop
End Sub
Thanks
the files that are not hidden. Is there a way to open all the files
regardless of hidden status.
Here is the code.
Sub open_all_files()
Dim path As Variant
Dim excelfile As Variant
path = "c:/users/caleb/documents/commissions experiment/"
excelfile = Dir(path & "*.xls")
Do While excelfile <> ""
Workbooks.Open Filename:=path & excelfile
excelfile = Dir
Loop
End Sub
Thanks