+ Reply to Thread
Results 1 to 7 of 7

save as xlsm to specific direction

  1. #1
    Forum Contributor
    Join Date
    03-22-2013
    Location
    Netherlands
    MS-Off Ver
    Excel 2016-2019
    Posts
    144

    save as xlsm to specific direction

    Halle forum users,

    I have a vba code that works for saving as pdf but now I also want to use this code for saving as xlsm.
    What do I have to change, I can't do it yet.


    Please Login or Register  to view this content.

  2. #2
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: save as xlsm to specific direction

    Hi,

    Are you wanting to save just the range B1:F53 on the sheet as a new workbook, or do you want to save the whole workbook?
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

  3. #3
    Forum Contributor
    Join Date
    03-22-2013
    Location
    Netherlands
    MS-Off Ver
    Excel 2016-2019
    Posts
    144

    Re: save as xlsm to specific direction

    Hello Richard,

    I want to save the whole workbook including the macro's.

    Regards.

  4. #4
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: save as xlsm to specific direction

    In that case then presumably



    Please Login or Register  to view this content.

  5. #5
    Forum Contributor
    Join Date
    03-22-2013
    Location
    Netherlands
    MS-Off Ver
    Excel 2016-2019
    Posts
    144

    Re: save as xlsm to specific direction

    It's working now but the filename is not okay. I need the name from cell C13!

  6. #6
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: save as xlsm to specific direction

    ..in that case for
    "MyFilename"

    just substitute

    Sheet1.Range("C13").Value

    obviously change the Sheet1 VBA sheet code name to whichever is the VBA sheet code name of the sheet with the C13 cell in question.
    Note, I'm talking about the VBA Sheet CODE name NOT the Excel Sheet TAB name.

  7. #7
    Forum Contributor
    Join Date
    03-22-2013
    Location
    Netherlands
    MS-Off Ver
    Excel 2016-2019
    Posts
    144

    Re: save as xlsm to specific direction

    Thanks for your reply.

    Grtz.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] Save as XLSX from XLSM and then delete the XLSM file?
    By LIL2606 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 05-29-2019, 08:56 AM
  2. [SOLVED] xlsm Save As xlsx, delete xlsm
    By cjjr82 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 09-25-2018, 05:15 PM
  3. Save sheet 1 of current WS, add a name and direction by msgbox
    By OoPan in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 08-12-2016, 04:29 AM
  4. [SOLVED] Save as xlsm file with specific name & specific folder
    By namialus in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 02-07-2015, 03:32 AM
  5. Replies: 2
    Last Post: 10-04-2013, 10:12 AM
  6. [SOLVED] Copy/Save As xlsm workbook to new xlsm workbook is not copying the code with it
    By Grinchy in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 08-02-2013, 09:30 AM
  7. Save file xls file as xlsm - macro won't run in xlsm workbook
    By captbluefin in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 11-07-2012, 11:39 AM

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