Just to add a little bit of trivia to this for reference purposes:
#1 - If <Test> has an .xls extension - means that somewhere along the line
it was likely saved with an "xlsx" extension (or any other of the '2007
extensions) and then "incorrectly" renamed to have an .xls extension (or
simply saved at the outset with the incorrect extension for the format
selected).
#2 - If you open a '2007 workbook that has been renamed/saved with an .xls
extension directly from within Excel - you will encounter at least one
intermediate message advising that the format of the file differs from the
extension and a response is required by the user - which likely explains
why "GetObject" failed in your scenario - nothing wrong with the GetObject
statement nor is there a glitch with O'2007 as per questions in original
post.
We have run across a couple of customer scenarios where .xls files have
been provided by a lead generation service via web download. These ".xls
files" were in fact '2007 files with more than 255 columns causing all
kinds of aggravation even just within Excel regardless of the extension
used. Rule of thumb - if Excel itself can't open a file without user
interaction of some kind or other - nothing else is going to work
seemlessly either.
Karl
--
____________________________________________________________
Karl Timmermans - The Claxton Group
ContactGenie - QuickPort/DataPort/Exporter/Toolkit/Duplicate Contact Mgr
"Contact import/export/data management tools for Outlook '2000/2010"
http://www.contactgenie.com