open an excel file that has spaces in the filename

pungentSapling

NeedHotSauce?
Local time
Today, 08:13
Joined
Apr 4, 2002
Messages
116
I am trying to work with a series of excel files from access that sometimes have spaces in the name..... example "Hello World.XLS" instead of "HelloWorld.XLS" I have no trouble opening space-free filenames but when there are spaces , I get a file not found error.

Is there a way to open files that have spaces using

... .workbooks.open("file name.xls")

or do I need to get all the files re-named?
thanks again
p
 
Hey pungentSapling,

try:
... .workbooks.open("""file name.xls""")
(three sets of double quotation marks)

-Sean
 
thanks.... there was two spaces in name!

as it turns out the reason it was not working was that there were two side by side spaces in the file name...... thanks for the help.
 
Which is exactly the reason why people should NOT use them !!!!
Not in filenames
DB's
Tables
querys

Anywhere in computer land (except for reports letters and stuff offcourse!

*Shaking my head*
Retorical: When will we ever learn?

*SIGH*

Regards
 
Hey Namlian,

I once worked on a database filled with names like:
"Query to determine what the latest status on a application is (with dates)". All of their folders on their network were like that too (not as bad as that one though).

Anyways - all to say that you're right, no spaces should be used (they just cause problems!)

-Sean
 

Users who are viewing this thread

Back
Top Bottom