LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 10
Default Hiding and protecting sheet without crashing Excel!

Hi,
I would like to hide a sheet and protect it at the same
time.
Excel crashes if I use the "hide" menu and then write the
following code in the Sub Workbook_Open():
With Worksheets("sheet1")
.EnableSelection = xlUnlockedCells
.Protect Contents:=True, Password:="xxx",
DrawingObjects:=True, UserInterfaceOnly:=True
End With

Any suggestion? Thanks
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
protecting formulas without protecting sheet so grouping still wor JM Excel Discussion (Misc queries) 1 June 4th 09 06:42 AM
Hiding and protecting formula The Greek Excel Discussion (Misc queries) 1 November 21st 07 06:14 PM
Excel 2003 - Protecting and Hiding Columns Peppermint Excel Discussion (Misc queries) 2 January 19th 06 04:06 PM
Protecting and Hiding formulas Pav New Users to Excel 3 May 23rd 05 12:25 AM
Hiding/Protecting vb code in excel IanStrange Excel Programming 1 November 10th 03 10:37 AM


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

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"