+ Reply to Thread
Results 1 to 3 of 3

Need VBA Command to save & exit and save as new file

  1. #1
    Forum Contributor
    Join Date
    04-30-2013
    Location
    washington
    MS-Off Ver
    Excel 2019
    Posts
    168

    Need VBA Command to save & exit and save as new file

    Hi experts

    I have excel file in module i have vba code i want save the file without module by command button

    i want add call vba permission code form in vba code

    Do you want close the save& exit or save as new file to particular path

    if i click Save and Exit then it save and close
    if i click save as new then it has to save to particular path "C:\Users\Windows 10\Desktop\VBA_Code\Westfield_report_todayyymmdd(22114).xlsx without macro file module


    Thanks

    Find the attachment
    Attached Files Attached Files

  2. #2
    Forum Expert Logit's Avatar
    Join Date
    12-23-2012
    Location
    North Carolina
    MS-Off Ver
    Excel 2019 Professional Plus - 2007 Enterprise
    Posts
    6,986

    Re: Need VBA Command to save & exit and save as new file

    The following will save itself without the macro code in the newly saved file. You'll need to edit the code to fit your
    specific circumstances :

    Please Login or Register  to view this content.

  3. #3
    Forum Contributor
    Join Date
    04-30-2013
    Location
    washington
    MS-Off Ver
    Excel 2019
    Posts
    168

    Re: Need VBA Command to save & exit and save as new file

    Dear sir its works but it open dialog box to confirm i want save to path once click button i want code on command button in userform 1
    if i click Save and exit ( current wb save and close
    if i click Save as New report i want save as new report to desired path with out open screen updating
    Attached Files Attached Files

+ 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 File Command Button
    By Jr66 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 05-22-2016, 03:03 AM
  2. Save Backup File to Different Location On Save and Exit
    By slindfors in forum Excel General
    Replies: 0
    Last Post: 06-16-2015, 09:01 AM
  3. [SOLVED] Button to place a time stamp, save the file, and exit
    By Taiter in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 06-20-2013, 12:48 PM
  4. Command line for open excel, insert a sheet, execute a macro, save file exit?
    By uschxc in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 03-26-2012, 12:28 PM
  5. [SOLVED] How do I make Command button ( Save & Exit) for Excel
    By Abutaha in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 11-16-2005, 06:45 PM
  6. [SOLVED] Run a dos batch file as soon as I exit/save the spreadsheet
    By Lynda in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 08-05-2005, 03:05 AM
  7. Intercepting Save and Exit menu command in Excel
    By PeteMann in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 08-04-2005, 07:05 PM

Tags for this Thread

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