+ Reply to Thread
Results 1 to 11 of 11

Need macro to disable "Save" and "Save as" buttons

  1. #1
    Registered User
    Join Date
    09-01-2012
    Location
    Paris, France
    MS-Off Ver
    Excel 2010
    Posts
    5

    Need macro to disable "Save" and "Save as" buttons

    Hello everyone,
    I need your help !

    I would like a macro (or some macros, I don't know) to be able to disable the "save" and "save as" buttons in Excel 2010 (my version).
    I just have put my excel sheet in "read-only" so other users can't save on the original file, but I need now to disable the buttons.

    I don't know nothing about VBA, so please put some details for the macro(s) : how and where I have to put it, etc..

    Thank you for any help !!

  2. #2
    Forum Contributor
    Join Date
    08-22-2012
    Location
    nj, us
    MS-Off Ver
    Excel 2010
    Posts
    163

    Re: Need macro to disable "Save" and "Save as" buttons

    is the "save as" and "Save" a command button? or just the button on taskbar?
    if button, then right click the button, then select properties, then on "enabled", select false

  3. #3
    Registered User
    Join Date
    09-01-2012
    Location
    Paris, France
    MS-Off Ver
    Excel 2010
    Posts
    5

    Re: Need macro to disable "Save" and "Save as" buttons

    The 2 buttons are not on taskbar, they are in the "File" tab, and I can't right click on them

    ---------- Post added at 03:34 PM ---------- Previous post was at 03:25 PM ----------

    and for information, my Excel is in english, even if I live in Paris lol.

  4. #4
    Forum Contributor
    Join Date
    08-22-2012
    Location
    nj, us
    MS-Off Ver
    Excel 2010
    Posts
    163

    Re: Need macro to disable "Save" and "Save as" buttons

    if in file tab, there is no way to disable them

  5. #5
    Registered User
    Join Date
    09-01-2012
    Location
    Paris, France
    MS-Off Ver
    Excel 2010
    Posts
    5

    Re: Need macro to disable "Save" and "Save as" buttons

    ohh
    ok thank you for your answers john !

  6. #6
    Registered User
    Join Date
    09-01-2012
    Location
    Paris, France
    MS-Off Ver
    Excel 2010
    Posts
    5

    Re: Need macro to disable "Save" and "Save as" buttons

    how do i mark as solved?

  7. #7
    Registered User
    Join Date
    09-01-2012
    Location
    Paris, France
    MS-Off Ver
    Excel 2010
    Posts
    5

    Re: Need macro to disable "Save" and "Save as" buttons

    yes i added

  8. #8
    Valued Forum Contributor WasWodge's Avatar
    Join Date
    08-02-2010
    Location
    Hampshire,England
    MS-Off Ver
    Office 365 and Office 2010
    Posts
    882

    Re: Need macro to disable "Save" and "Save as" buttons

    Anforya, it is not disabling the buttons but the code below should prevent a save. Place the code in the ThisWorkbook module

    Please Login or Register  to view this content.
    To allow you to save, in the code window press CTRL + G to open the Immediate Window, type

    Application.EnableEvents=False
    and press Enter.

    To re-enable events
    Application.EnableEvents=True

    Obviously this won't work if they don't enable the macros.
    Last edited by WasWodge; 09-01-2012 at 12:50 PM.
    If my solution worked (or not) please let me know. If your question is answered then please remember to mark it solved

    Computers are like air conditioners. They work fine until you start opening windows. ~Author Unknown

  9. #9
    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: Need macro to disable "Save" and "Save as" buttons

    Quote Originally Posted by john456852 View Post
    if in file tab, there is no way to disable them
    John

    This is the second of your posts today where you have given the wrong answer.

    It is complicated, but not impossible to disable the Save and Save As items in the Office Button.
    See http://msdn.microsoft.com/en-us/library/aa722523.aspx

    Can I remove the Microsoft Office Button?

    "You can disable or hide all of the items on the Microsoft Office Button menu, but you cannot remove the button itself."
    Please take more care
    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.

  10. #10
    Forum Contributor
    Join Date
    09-05-2013
    Location
    Spring, Tx
    MS-Off Ver
    Excel 365
    Posts
    122

    Re: Need macro to disable "Save" and "Save as" buttons

    Is it possible to have a similar macro for when the sheet is opened as read only? I have a Worksheet that I only want certain people to be able to Open and edit but everyone else can open in Read only. I have tried all the built in features but the read only still ask the user if they want to save when exiting. If they select Yes it saves a copy and i don't want to end up with tons of copies. So is there a macro that prevents the the save pop up when open as read only and just closes the sheet?
    Last edited by zhead; 12-20-2013 at 12:06 PM.

  11. #11
    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: Need macro to disable "Save" and "Save as" buttons

    Hi and welcome to the forum.

    Unfortunately your post does not comply with Rule 2 of our Forum RULES. Do not post a question in the thread of another member -- start your own thread.

    If you feel an existing thread is particularly relevant to your need, provide a link to the other thread in your new thread.

    Old threads are often only monitored by the original participants. New threads not only open you up to all possible participants again, they typically get faster response, too.

+ 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