As David mentioned, the Excel 2007/2010 file extension for macros is .xlsm
But, just to throw my 2 cents in:
unless you're using xml in your macros, I prefer .xlsb format
Microsoft says it's a "binary" format.
Now, your file might not be very large, and the difference is more noticeable
with large files,
but I've found that .xlsb files load faster and macros run faster than in .xlsm
format.
and the file size is much smaller too!
(I have a file that's 50.2Mb as an .xlsm format and takes 15 seconds to load,
in .xlsb format, it's only 15.7Mb and loads in 4 seconds.)
There... that's my 2 cents.
Paul
-----------------------------------------
"Do all the good you can,
By all the means you can,
In all the ways you can,
In all the places you can,
At all the times you can,
To all the people you can,
As long as ever you can." - John Wesley
-----------------------------------------
________________________________
From: David Grugeon <yahoo@grugeon.com.au>
To: ExcelVBA@yahoogroups.com
Sent: Thu, March 7, 2013 2:47:46 AM
Subject: RE: [ExcelVBA] saving files either as XLS or XLSM
You probably don't want .xlm It is .xlsm
Best Regards
David Grugeon
Excel VBA Group Moderator
-----Original Message-----
From: ExcelVBA@yahoogroups.com [mailto:ExcelVBA@yahoogroups.com] On Behalf
Of sunnywulf
Sent: Thursday, 7 March 2013 2:33 PM
To: ExcelVBA@yahoogroups.com
Subject: [ExcelVBA] saving files either as XLS or XLSM
I am struggling with this and and hope somebody can help.
A workbook in Excel versions 2003, 2007 or 2010 has macros and need to be
saved. In the Before_Save event I check for the excel version and only allow
saving as XLS for 2003 or XLS or XLM (due to macros) for 2007 and 2010
version.
For 2003, it is easy:
FName = Application.GetSaveAsFilename(FileFilter:="Excel 97-2003 Workbook
(*.xls), *.xls")
But what is the proper command for 2007 and 2010 to set two file filters?
The following doesn't work:
FName = Application.GetSaveAsFilename(FileFilter:="Excel Macro-Enabled
Workbook (*.xlm), *.xlm", "Excel 97-2003 Workbook (*.xls), *.xls")
Your help is greatly appreciated.
Wolfram
------------------------------------
----------------------------------
Be sure to check out TechTrax Ezine for many, free Excel VBA articles! Go
here: http://www.mousetrax.com/techtrax to enter the ezine, then search the
ARCHIVES for EXCEL VBA.
----------------------------------
Visit our ExcelVBA group home page for more info and support files:
http://groups.yahoo.com/group/ExcelVBA
----------------------------------
More free tutorials and resources available at:
http://www.mousetrax.com
----------------------------------Yahoo! Groups Links
[Non-text portions of this message have been removed]
Reply via web post | Reply to sender | Reply to group | Start a New Topic | Messages in this topic (4) |
Be sure to check out TechTrax Ezine for many, free Excel VBA articles! Go here: http://www.mousetrax.com/techtrax to enter the ezine, then search the ARCHIVES for EXCEL VBA.
----------------------------------
Visit our ExcelVBA group home page for more info and support files:
http://groups.yahoo.com/group/ExcelVBA
----------------------------------
More free tutorials and resources available at:
http://www.mousetrax.com
----------------------------------
Tidak ada komentar:
Posting Komentar