+ Reply to Thread
Results 1 to 3 of 3

File Format equals Marco-Enabled Workbook

  1. #1
    Registered User
    Join Date
    10-09-2008
    Location
    Denver
    Posts
    4

    File Format equals Marco-Enabled Workbook

    Within my VBA code, I want to save the Excel file as "Excel Macro-Enabled Workbook." Currently, File Format:=xlNormal within the VBA code and the results saves the Excel file as .xls. How do I write the File Format to save the Excel file as "Excel Macro-Enabled Workbook."

    Below is an example:
    ActiveWorkbook.SaveAs Filename:=Left$(ActiveWorkbook.Name, (Len(ActiveWorkbook.Name) - 4)), FileFormat:=xlNormal, CreateBackup:=False
    Last edited by markcicoff; 02-06-2009 at 02:43 PM.

  2. #2
    Forum Expert dominicb's Avatar
    Join Date
    01-25-2005
    Location
    Lancashire, England
    MS-Off Ver
    MS Office 2000, 2003, 2007 & 2016 365
    Posts
    4,867

    Smile Re: File Format equals Marco-Enabled Workbook

    Good evening markcicoff
    Quote Originally Posted by markcicoff View Post
    Within my VBA code, I want to save the Excel file as "Excel Macro-Enabled Workbook." Currently, File Format:=xlNormal within the VBA code and the results saves the Excel file as .xls. How do I write the File Format to save the Excel file as "Excel Macro-Enabled Workbook."
    Unfortunately, there is no such thing as a macro enabled workbook. A user can control his / her own macro security settings and determine whether macros can be run or not.

    It's a deliberate thing by Microsoft in the name of security and it's non negotiable.

    HTH

    DominicB
    Please familiarise yourself with the rules before posting. You can find them here.

  3. #3
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: File Format equals Marco-Enabled Workbook

    Are you using Excel 2007?
    Hope that helps.

    RoyUK
    --------
    For Excel Tips & Solutions, free examples and tutorials why not check out my web site

    Free DataBaseForm example

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1