Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Another possibility:
Dir doesn't return the path in sFileName, so Dim sPath as String, sFileName as String sPath = "H:\Risk_Management\Special_Review\Upload_file s\" sFileName = Dir(sPath & "*.xls") if sFileName < "" then workbooks.Open Filename:=sPath & sFileName Else msgbox "No excel workbooks" End if -- Regards, Tom Ogilvy *.xls") Workbooks.Open Filename:=sFilename "Robert" wrote: Hello, When I walk through the following statement I get a run time error 1004 that says that the particular file couls not be found. I used the following statement: sFilename = Dir("H:\Risk_Management\Special_Review\Upload_file s\*.xls") Workbooks.Open Filename:=sFilename Do I forgot something? Thanks for your assistance!! Rgds, Robert |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Unable to open a 82 KB XLSM file due to "Too many different cellformats" & "Converter failed to open the file." errors. | Setting up and Configuration of Excel | |||
In Excel - Use Windows Explorer instead of File Open to open file | Excel Discussion (Misc queries) | |||
Open a file do a macro ( made) and open next succesive file | Excel Programming | |||
Open File or Switch Between Windows if File is Open | Excel Programming | |||
Open File or Switch Between Windows if File is Open | Excel Programming |