Home |
Search |
Today's Posts |
#10
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
On Monday, January 12, 2015 at 10:18:47 PM UTC-8, GS wrote:
No, I did not know that. Have not heard of it. How would it be used in this code, perhaps like EnableEvents False/True at the beginning and end? Howard With some reading, seems it must be in a WorkBookOpen event. If that is true, I will probably need to stay with the UnProtect/Protect method. Howard Not advised since it can be handled in 1 place instead of every procedure that needs to act on a sheet. Also, I note that your password is hard-coded! Better to use a constant. Okay, this is all new ground for me and the OP is wanting to add, edit or delete comments on a sheet, as easily as she can. She will be the messenger with the code to her people and is at the edge of Excel knowledge with the code I posted here. I would be reluctant to step into this "new to me" UserInterfaceOnly at this time on this macro. Howard. My point is that you don't have any error handling code in your procedure[s]! Sooo.., should an error occur then your sheet gets left unprotected. Using my suggestion at startup obviates the need for extra error handling code IN EVERY PROCEDURE where you toggle protection to make changes. Otherwise, I suggest adding error handling! Optionally, you can specify which sheets get protected and what level of protection is applied to each sheet. The latter, though, is a bit more complex than the simple code I exampled. -- Garry Free usenet access at http://www.eternal-september.org Classic VB Users Regroup! comp.lang.basic.visual.misc microsoft.public.vb.general.discussion |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
ActiveCell.Offset(i, 0) = Chr(ActiveCell.Row + 62) returns all A's | Excel Programming | |||
Amend sub to re-hide comment when activecell change to another | Excel Programming | |||
Exit Field vs Exit Button...... | Excel Programming | |||
If activecell.column = variable then activecell,offset (0,1) | Excel Discussion (Misc queries) | |||
If a called sub exit, how to the caller exit right away? | Excel Programming |