+ Reply to Thread
Results 1 to 5 of 5

Application.DisplayAlerts

  1. #1
    TK
    Guest

    Application.DisplayAlerts

    Hi:

    The following does not stop the alert message box if
    an attempt is made to enter data into a protected cell.
    Any advice as to how to stop the alerts would be greatly
    appreciated.

    Private Sub Worksheet_Activate()
    Worksheets("Sheet1").Unprotect
    Application.DisplayAlerts = False
    Worksheets("Sheet1").Protect
    End Sub

    Thanks
    TK



  2. #2
    Paul B
    Guest

    Re: Application.DisplayAlerts

    TK, you cannot enter data into a proctected cell, locked cell,

    By default all cells in excel are protected or locked, select the cells you
    want to unlock and go to format, cells, protection and uncheck locked, the
    go to tools, protection, and protect sheet, enter a password if you want,
    now only the cells that you unlocked can be edited.

    If you only need a few locked I would select them all first, Ctrl A, then
    go to format, cells, protection and uncheck locked, then select the cells
    you want to lock and go to format cells and check locked, the go to tools,
    protection, and protect sheet, enter a password if you want, now the cells
    that you locked can not be edited


    --
    Paul B
    Always backup your data before trying something new
    Please post any response to the newsgroups so others can benefit from it
    Feedback on answers is always appreciated!
    Using Excel 2002 & 2003

    "TK" <[email protected]> wrote in message
    news:[email protected]...
    > Hi:
    >
    > The following does not stop the alert message box if
    > an attempt is made to enter data into a protected cell.
    > Any advice as to how to stop the alerts would be greatly
    > appreciated.
    >
    > Private Sub Worksheet_Activate()
    > Worksheets("Sheet1").Unprotect
    > Application.DisplayAlerts = False
    > Worksheets("Sheet1").Protect
    > End Sub
    >
    > Thanks
    > TK
    >
    >




  3. #3
    TK
    Guest

    Re: Application.DisplayAlerts

    Thanks Paul:

    I probably was not clear. I’m familiar with the sheet
    protecting procedure. I’m trying to stop the caution
    alert if a user tries to inadvertently enter data into a
    protected cell. Obviously, they cannot enter data I just
    do not want them to be reminded that they cannot.

    Thanks
    TK




    "Paul B" wrote:

    > TK, you cannot enter data into a proctected cell, locked cell,
    >
    > By default all cells in excel are protected or locked, select the cells you
    > want to unlock and go to format, cells, protection and uncheck locked, the
    > go to tools, protection, and protect sheet, enter a password if you want,
    > now only the cells that you unlocked can be edited.
    >
    > If you only need a few locked I would select them all first, Ctrl A, then
    > go to format, cells, protection and uncheck locked, then select the cells
    > you want to lock and go to format cells and check locked, the go to tools,
    > protection, and protect sheet, enter a password if you want, now the cells
    > that you locked can not be edited
    >
    >
    > --
    > Paul B
    > Always backup your data before trying something new
    > Please post any response to the newsgroups so others can benefit from it
    > Feedback on answers is always appreciated!
    > Using Excel 2002 & 2003
    >
    > "TK" <[email protected]> wrote in message
    > news:[email protected]...
    > > Hi:
    > >
    > > The following does not stop the alert message box if
    > > an attempt is made to enter data into a protected cell.
    > > Any advice as to how to stop the alerts would be greatly
    > > appreciated.
    > >
    > > Private Sub Worksheet_Activate()
    > > Worksheets("Sheet1").Unprotect
    > > Application.DisplayAlerts = False
    > > Worksheets("Sheet1").Protect
    > > End Sub
    > >
    > > Thanks
    > > TK
    > >
    > >

    >
    >
    >


  4. #4
    Paul B
    Guest

    Re: Application.DisplayAlerts

    TK, I don't think you can cut off that alert, how about not letting them
    select the locked cells? If you are using excel 2002 or newer when you
    protect the sheet uncheck select locked cells, if you have an early version
    you can use a macro like this in the thisworkbook module

    Private Sub Workbook_Open()
    'will not let you select locked cells
    'This is a setting that excel doesn't remember between closings,so have
    'your workbook_open code do it each time:
    With Worksheets("sheet1") 'change to your sheet name
    ..Activate
    ..EnableSelection = xlUnlockedCells

    'change password here
    ..Protect Password:="123", Contents:=True, UserInterfaceOnly:=True
    End With
    End Sub


    --
    Paul B
    Always backup your data before trying something new
    Please post any response to the newsgroups so others can benefit from it
    Feedback on answers is always appreciated!
    Using Excel 2002 & 2003

    "TK" <[email protected]> wrote in message
    news:[email protected]...
    > Thanks Paul:
    >
    > I probably was not clear. I'm familiar with the sheet
    > protecting procedure. I'm trying to stop the caution
    > alert if a user tries to inadvertently enter data into a
    > protected cell. Obviously, they cannot enter data I just
    > do not want them to be reminded that they cannot.
    >
    > Thanks
    > TK
    >
    >
    >
    >
    > "Paul B" wrote:
    >
    >> TK, you cannot enter data into a proctected cell, locked cell,
    >>
    >> By default all cells in excel are protected or locked, select the cells
    >> you
    >> want to unlock and go to format, cells, protection and uncheck locked,
    >> the
    >> go to tools, protection, and protect sheet, enter a password if you want,
    >> now only the cells that you unlocked can be edited.
    >>
    >> If you only need a few locked I would select them all first, Ctrl A,
    >> then
    >> go to format, cells, protection and uncheck locked, then select the cells
    >> you want to lock and go to format cells and check locked, the go to
    >> tools,
    >> protection, and protect sheet, enter a password if you want, now the
    >> cells
    >> that you locked can not be edited
    >>
    >>
    >> --
    >> Paul B
    >> Always backup your data before trying something new
    >> Please post any response to the newsgroups so others can benefit from it
    >> Feedback on answers is always appreciated!
    >> Using Excel 2002 & 2003
    >>
    >> "TK" <[email protected]> wrote in message
    >> news:[email protected]...
    >> > Hi:
    >> >
    >> > The following does not stop the alert message box if
    >> > an attempt is made to enter data into a protected cell.
    >> > Any advice as to how to stop the alerts would be greatly
    >> > appreciated.
    >> >
    >> > Private Sub Worksheet_Activate()
    >> > Worksheets("Sheet1").Unprotect
    >> > Application.DisplayAlerts = False
    >> > Worksheets("Sheet1").Protect
    >> > End Sub
    >> >
    >> > Thanks
    >> > TK
    >> >
    >> >

    >>
    >>
    >>




  5. #5
    TK
    Guest

    Re: Application.DisplayAlerts

    Thanks Paul:

    I guess your right. My confusion came from the fact
    that I was able to set displayAlerts = False when
    changing pages using a macro. This I found you can do
    via (Microsoft Library). Not so with the page selector.
    I got that idea from post :
    “Stop Message To Unprotect” 11/11/2004

    Good Luck
    TK


    "Paul B" wrote:

    > TK, I don't think you can cut off that alert, how about not letting them
    > select the locked cells? If you are using excel 2002 or newer when you
    > protect the sheet uncheck select locked cells, if you have an early version
    > you can use a macro like this in the thisworkbook module
    >
    > Private Sub Workbook_Open()
    > 'will not let you select locked cells
    > 'This is a setting that excel doesn't remember between closings,so have
    > 'your workbook_open code do it each time:
    > With Worksheets("sheet1") 'change to your sheet name
    > ..Activate
    > ..EnableSelection = xlUnlockedCells
    >
    > 'change password here
    > ..Protect Password:="123", Contents:=True, UserInterfaceOnly:=True
    > End With
    > End Sub
    >
    >
    > --
    > Paul B
    > Always backup your data before trying something new
    > Please post any response to the newsgroups so others can benefit from it
    > Feedback on answers is always appreciated!
    > Using Excel 2002 & 2003
    >
    > "TK" <[email protected]> wrote in message
    > news:[email protected]...
    > > Thanks Paul:
    > >
    > > I probably was not clear. I'm familiar with the sheet
    > > protecting procedure. I'm trying to stop the caution
    > > alert if a user tries to inadvertently enter data into a
    > > protected cell. Obviously, they cannot enter data I just
    > > do not want them to be reminded that they cannot.
    > >
    > > Thanks
    > > TK
    > >
    > >
    > >
    > >
    > > "Paul B" wrote:
    > >
    > >> TK, you cannot enter data into a proctected cell, locked cell,
    > >>
    > >> By default all cells in excel are protected or locked, select the cells
    > >> you
    > >> want to unlock and go to format, cells, protection and uncheck locked,
    > >> the
    > >> go to tools, protection, and protect sheet, enter a password if you want,
    > >> now only the cells that you unlocked can be edited.
    > >>
    > >> If you only need a few locked I would select them all first, Ctrl A,
    > >> then
    > >> go to format, cells, protection and uncheck locked, then select the cells
    > >> you want to lock and go to format cells and check locked, the go to
    > >> tools,
    > >> protection, and protect sheet, enter a password if you want, now the
    > >> cells
    > >> that you locked can not be edited
    > >>
    > >>
    > >> --
    > >> Paul B
    > >> Always backup your data before trying something new
    > >> Please post any response to the newsgroups so others can benefit from it
    > >> Feedback on answers is always appreciated!
    > >> Using Excel 2002 & 2003
    > >>
    > >> "TK" <[email protected]> wrote in message
    > >> news:[email protected]...
    > >> > Hi:
    > >> >
    > >> > The following does not stop the alert message box if
    > >> > an attempt is made to enter data into a protected cell.
    > >> > Any advice as to how to stop the alerts would be greatly
    > >> > appreciated.
    > >> >
    > >> > Private Sub Worksheet_Activate()
    > >> > Worksheets("Sheet1").Unprotect
    > >> > Application.DisplayAlerts = False
    > >> > Worksheets("Sheet1").Protect
    > >> > End Sub
    > >> >
    > >> > Thanks
    > >> > TK
    > >> >
    > >> >
    > >>
    > >>
    > >>

    >
    >
    >


+ 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