Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 57
Default Macro to save 2007 file in 97-2003 format

I'm trying to make a macro that will automatically save an Excel 2007 file
in the 97-2003 file format. So far I have this:
ActiveWorkbook.SaveAs Filename:=ActiveWorkbook.FullName, _
FileFormat:=xlExcel8, Password:="", WriteResPassword:="", _
ReadOnlyRecommended:=False, CreateBackup:=False

The Active Workbook.FullName wants to save the file with the .xlsm extension
though the FileFormat=xlExcel8, so I'm confued. Help, please.


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,123
Default Macro to save 2007 file in 97-2003 format

Look here
http://www.rondebruin.nl/saveas.htm

--

Regards Ron de Bruin
http://www.rondebruin.nl/tips.htm




"John" wrote in message ...
I'm trying to make a macro that will automatically save an Excel 2007 file
in the 97-2003 file format. So far I have this:
ActiveWorkbook.SaveAs Filename:=ActiveWorkbook.FullName, _
FileFormat:=xlExcel8, Password:="", WriteResPassword:="", _
ReadOnlyRecommended:=False, CreateBackup:=False

The Active Workbook.FullName wants to save the file with the .xlsm extension
though the FileFormat=xlExcel8, so I'm confued. Help, please.


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,510
Default Macro to save 2007 file in 97-2003 format

If you were to run the following line of code just before the save you would
see that you have the .xlsm extension on the name you are using to save the
file.

You need to create a variable for the current name and then replace the
..xlsm with .xls.

MsgBox ActiveWorkbook.FullName

--
Regards,

OssieMac


"John" wrote:

I'm trying to make a macro that will automatically save an Excel 2007 file
in the 97-2003 file format. So far I have this:
ActiveWorkbook.SaveAs Filename:=ActiveWorkbook.FullName, _
FileFormat:=xlExcel8, Password:="", WriteResPassword:="", _
ReadOnlyRecommended:=False, CreateBackup:=False

The Active Workbook.FullName wants to save the file with the .xlsm extension
though the FileFormat=xlExcel8, so I'm confued. Help, please.



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
2007 Macro to Open File, Delete Contents, Save New File Flintstone[_2_] Excel Discussion (Misc queries) 2 February 1st 10 11:25 PM
How do I save a 2007 ex file so another party can open with 2003 Mel Excel Discussion (Misc queries) 2 September 14th 08 11:00 PM
Setting all users to save Excel 2007 files in 2003 format Owen K Excel Discussion (Misc queries) 0 August 16th 08 01:31 AM
save excel file in tiff format in 2007 maryann Excel Discussion (Misc queries) 1 July 25th 08 02:51 PM
Using Macro to Save xls to txt without changing file format SSciarrino Excel Programming 0 November 1st 04 06:15 PM


All times are GMT +1. The time now is 01:05 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"