ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Unhide sheet on open only if password to modify is given (https://www.excelbanter.com/excel-programming/385162-unhide-sheet-open-only-if-password-modify-given.html)

ALEX

Unhide sheet on open only if password to modify is given
 
I currently have a sheet hidden on file/open. I have set the file/save
option to a password to modify. Is there a way to unhide the sheet only if
the password to modify is given, but hide it if the file is opened as
read-only? Thanks

Dave Peterson

Unhide sheet on open only if password to modify is given
 
You could check:

if thisworkbook.ReadOnly then
'do one thing
else
'do something else
end if



Alex wrote:

I currently have a sheet hidden on file/open. I have set the file/save
option to a password to modify. Is there a way to unhide the sheet only if
the password to modify is given, but hide it if the file is opened as
read-only? Thanks


--

Dave Peterson


All times are GMT +1. The time now is 05:20 PM.

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