Solved

vba to save xls file without macros

Posted on 2012-03-20
5
242 Views
Last Modified: 2012-03-21
Hi!
I have an excel file containing a macro. As the last step, the macro saves the file as an xlsx, so that it can be distributed via email without the macro.
I now need to duplicate this for users in Excel 2003. How can I do this?
Here is my current code:

Application.DisplayAlerts = False
Application.EnableEvents = False
    ActiveWorkbook.SaveAs Filename:= _
        "F:\buying\catalog production\2013\" & FName & ".xlsx", FileFormat:=xlOpenXMLWorkbook, ReadOnlyRecommended:=False, CreateBackup:=False
Application.EnableEvents = True
Application.DisplayAlerts = True

Open in new window


Thanks!
0
Comment
Question by:etech0
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 6

Expert Comment

by:wshark83
ID: 37742960
have you tried just changing the xlsx extention to xls...?
0
 
LVL 10

Author Comment

by:etech0
ID: 37742980
Will it then save without the macro?
0
 
LVL 10

Author Comment

by:etech0
ID: 37742991
I tested it - it saves with the macros. What I need is for it to save without, so I can email it to many people without encountering 'email' issues.
0
 
LVL 6

Accepted Solution

by:
wshark83 earned 500 total points
ID: 37743378
0
 
LVL 10

Author Closing Comment

by:etech0
ID: 37749764
Thanks!
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This code takes an Excel list of URL’s and adds a header titled “URL List”. It then searches through all URL’s in column “A”, looking for duplicates. When a duplicate is found, it is moved to the top of the list. The duplicate URL’s are then highlig…
Access developers frequently have requirements to interact with Excel (import from or output to) in their applications.  You might be able to accomplish this with the TransferSpreadsheet and OutputTo methods, but in this series of articles I will di…
This Micro Tutorial will demonstrate how to use longer labels with horizontal bar charts instead of the vertical column chart.
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question