Have an excel file that imports other excel files, however when I open one of the files, it is corrupt and says...
"We found a problem with some content... blah blah... recover as much as we can.. yes or no?"
My code is the below and it currently opens the file and closes it, I think it is getting stuck at the error message. Any ideas?
Application.DisplayAlerts = False
Application.EnableEvents = False
Workbooks.Open (ARFile), UpdateLinks:=Yes
Application.DisplayAlerts = True
Application.EnableEvents = True
Edit - I condensed the code to just target the file and it opens the file then says "Method Open of Object Workbooks' Failed" and closes
Workbooks.Open ("C:UsersobDesktopClientProjectD-F - All
Reports_3018489300_030117_103117 .xlsx")
See Question&Answers more detail:os