Full Version: Saving A Specific Excel Version
UtterAccess Discussion Forums > Microsoft® Office > Microsoft Excel
rmd1401
OK. I am creating an excel file from a .xlt file.

I am doing this from MS Access 2010...and therefore, I am also using the MS Excel 2010 object model in the VBA.

I am trying to save as .xls filetype (97-2003) because a corporate system I upload it into, of course, does not know that MS Office 2007 came out 5 years ago.

I use the below:
CODE
wbXlWorkbook.SaveAs strInputFileName, 52


wbXlWorkbook being my MS Excel workbook object.

It is not saving as .xls. The system I interface it with spits an error. I always go back and save the file again as .xls, and it indicates it is currently in .xlsm (when opening says mismatch in extension/filetype warning).

I originally had trouble finding the right value to use for saving. I though '52' was the appropriate value to use with the .SaveAs method to get my desired result. Anyone know which value to use? 52 appears to be .xlsm, not .xls.

Thanks-
ipisors
Best page on this:

http://www.rondebruin.nl/saveas.htm
rmd1401
Indeed, I needed '56' instead. Must have been on a slightly different site before, or misinterpreted.

Thanks for your help.
ipisors
Glad I could help (thanks Ron!)
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.