+ Reply to Thread
Results 1 to 5 of 5

How can I make File->Save , File->SaveAs Menu disabled?

  1. #1
    Zoo
    Guest

    How can I make File->Save , File->SaveAs Menu disabled?

    Hi,
    Can I make File->Save and File->SaveAs Menu of Excel.exe disabled
    by using any WIN32API or other ways?
    Making them invisible is the best for me, but making them gray is also good
    for me.
    Thanks in advance.

    (Win2000+Excel2002)


  2. #2
    Bob Phillips
    Guest

    Re: How can I make File->Save , File->SaveAs Menu disabled?

    With Application.CommandBars("Worksheet Menu Bar").Controls("File")
    .Controls("Save").Visible = False
    .Controls("Save As Menu").Visible = False
    End With

    Don't forget to put them back.

    --
    HTH

    Bob Phillips

    (replace somewhere in email address with gmail if mailing direct)

    "Zoo" <[email protected]> wrote in message
    news:[email protected]...
    > Hi,
    > Can I make File->Save and File->SaveAs Menu of Excel.exe disabled
    > by using any WIN32API or other ways?
    > Making them invisible is the best for me, but making them gray is also

    good
    > for me.
    > Thanks in advance.
    >
    > (Win2000+Excel2002)
    >




  3. #3
    Chip Pearson
    Guest

    Re: How can I make File->Save , File->SaveAs Menu disabled?

    > .Controls("Save As Menu").Visible = False

    should be

    .Controls("Save As...").Visible = False

    While these will disable the menu items, the user can still do a
    Save with CTRL+S

    To actually disable saving, put the following code in the
    ThisWorkbook code module:

    Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel
    As Boolean)
    ThisWorkbook.Saved = True
    Cancel = True
    End Sub


    --
    Cordially,
    Chip Pearson
    Microsoft MVP - Excel
    Pearson Software Consulting, LLC
    www.cpearson.com


    "Bob Phillips" <[email protected]> wrote in message
    news:[email protected]...
    > With Application.CommandBars("Worksheet Menu
    > Bar").Controls("File")
    > .Controls("Save").Visible = False
    > .Controls("Save As Menu").Visible = False
    > End With
    >
    > Don't forget to put them back.
    >
    > --
    > HTH
    >
    > Bob Phillips
    >
    > (replace somewhere in email address with gmail if mailing
    > direct)
    >
    > "Zoo" <[email protected]> wrote in message
    > news:[email protected]...
    >> Hi,
    >> Can I make File->Save and File->SaveAs Menu of Excel.exe
    >> disabled
    >> by using any WIN32API or other ways?
    >> Making them invisible is the best for me, but making them gray
    >> is also

    > good
    >> for me.
    >> Thanks in advance.
    >>
    >> (Win2000+Excel2002)
    >>

    >
    >




  4. #4
    Bob Phillips
    Guest

    Re: How can I make File->Save , File->SaveAs Menu disabled?

    I didn't know what Save As Menu was, so assumed it was something 2003 (which
    I don't use) <g>

    --
    HTH

    Bob Phillips

    (replace somewhere in email address with gmail if mailing direct)

    "Chip Pearson" <[email protected]> wrote in message
    news:%[email protected]...
    > > .Controls("Save As Menu").Visible = False

    >
    > should be
    >
    > .Controls("Save As...").Visible = False
    >
    > While these will disable the menu items, the user can still do a
    > Save with CTRL+S
    >
    > To actually disable saving, put the following code in the
    > ThisWorkbook code module:
    >
    > Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel
    > As Boolean)
    > ThisWorkbook.Saved = True
    > Cancel = True
    > End Sub
    >
    >
    > --
    > Cordially,
    > Chip Pearson
    > Microsoft MVP - Excel
    > Pearson Software Consulting, LLC
    > www.cpearson.com
    >
    >
    > "Bob Phillips" <[email protected]> wrote in message
    > news:[email protected]...
    > > With Application.CommandBars("Worksheet Menu
    > > Bar").Controls("File")
    > > .Controls("Save").Visible = False
    > > .Controls("Save As Menu").Visible = False
    > > End With
    > >
    > > Don't forget to put them back.
    > >
    > > --
    > > HTH
    > >
    > > Bob Phillips
    > >
    > > (replace somewhere in email address with gmail if mailing
    > > direct)
    > >
    > > "Zoo" <[email protected]> wrote in message
    > > news:[email protected]...
    > >> Hi,
    > >> Can I make File->Save and File->SaveAs Menu of Excel.exe
    > >> disabled
    > >> by using any WIN32API or other ways?
    > >> Making them invisible is the best for me, but making them gray
    > >> is also

    > > good
    > >> for me.
    > >> Thanks in advance.
    > >>
    > >> (Win2000+Excel2002)
    > >>

    > >
    > >

    >
    >




  5. #5
    Zoo
    Guest

    Re: How can I make File->Save , File->SaveAs Menu disabled?

    Thank you , Bob.
    I'm happy to know that he solution is so much easier than I thought.
    That helps me so much.


    "Bob Phillips" <[email protected]> wrote in message
    news:[email protected]...
    > With Application.CommandBars("Worksheet Menu Bar").Controls("File")
    > .Controls("Save").Visible = False
    > .Controls("Save As Menu").Visible = False
    > End With
    >
    > Don't forget to put them back.
    >
    > --
    > HTH
    >
    > Bob Phillips
    >
    > (replace somewhere in email address with gmail if mailing direct)
    >
    > "Zoo" <[email protected]> wrote in message
    > news:[email protected]...
    > > Hi,
    > > Can I make File->Save and File->SaveAs Menu of Excel.exe disabled
    > > by using any WIN32API or other ways?
    > > Making them invisible is the best for me, but making them gray is also

    > good
    > > for me.
    > > Thanks in advance.
    > >
    > > (Win2000+Excel2002)
    > >

    >
    >



+ 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