ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Protection Message (https://www.excelbanter.com/excel-programming/299605-protection-message.html)

fred

Protection Message
 
When a worksheet is protected and a cell is locked then an Error message
appears whenever the user attempts to edit the cell.
Is there an event that I can tap into so that I can display my own message
and run my own routine instead of the standard message?

Thanks for any help
Fred



JE McGimpsey

Protection Message
 
AFAIK, no.

In article ,
"Fred" <leavemealone@home wrote:

When a worksheet is protected and a cell is locked then an Error message
appears whenever the user attempts to edit the cell.
Is there an event that I can tap into so that I can display my own message
and run my own routine instead of the standard message?

Thanks for any help
Fred


Dave Peterson[_3_]

Protection Message
 
Maybe you could just stop them from selecting locked cells on your worksheet:

Option Explicit
Sub auto_open()
With Worksheets("Sheet1")
.Protect Password:="hi"
.EnableSelection = xlUnlockedCells
End With
End Sub

And xl2002 added the ability to set the enableselection property via the
userinterface.

Fred wrote:

When a worksheet is protected and a cell is locked then an Error message
appears whenever the user attempts to edit the cell.
Is there an event that I can tap into so that I can display my own message
and run my own routine instead of the standard message?

Thanks for any help
Fred


--

Dave Peterson



All times are GMT +1. The time now is 02:13 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com