Link to home
Start Free TrialLog in
Avatar of Frank Freese
Frank FreeseFlag for United States of America

asked on

Change Excel system messages

Folks,
When certain cells in a worksheet are protected Excel gives you a message. Is there anyway to create your own messages and not use Excel's? I know in Access you can capture the error code and generate your own message so I was wondering if you could not do the same in Excel.
ASKER CERTIFIED SOLUTION
Avatar of rspahitz
rspahitz
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Frank Freese

ASKER

Thanks - looks like the same thing in Access - I'll try it this afternoon
SOLUTION
Avatar of Jacques Geday
Jacques Geday
Flag of Canada image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
@rspahitz
Your code is simply error handling and will not react when sheet is protected.
gowflow
Thank you folks...I can see me incorporating both suggestions.
Good work - 50/50 spread
all good suggestions
appreciate all the experts very much
Glad that the information was useful.  It's always good practice to put error-trapping in any piece of code (*) that could potentially create an error (and in Excel, it's almost every piece of code.)

(*) subs called by error-handled methods may not need error-traps if you don't mind the error floating up, but then you typically lose access to the line or other information about where the error occurred.