#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 74
Default protecting a sheet

please help. is it possible to password protect only one sheet in workbook?
if so, could anyone please help. can i incorporate the script into an
existing macro?
thanks
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,501
Default protecting a sheet

Try this

Sub Sonic()
'Do lots of things
Sheets("Sheet1").Protect Password:="Mypass"
End Sub

Mike

"des-sa" wrote:

please help. is it possible to password protect only one sheet in workbook?
if so, could anyone please help. can i incorporate the script into an
existing macro?
thanks

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,058
Default protecting a sheet

Sub Macro1()
ActiveSheet.Protect DrawingObjects:=True, Contents:=True, Scenarios:=True
End Sub

--
Gary''s Student - gsnu200827


"des-sa" wrote:

please help. is it possible to password protect only one sheet in workbook?
if so, could anyone please help. can i incorporate the script into an
existing macro?
thanks

  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,722
Default protecting a sheet

From XL
Tools-Protection-Protect sheet

From VBA (w/ password)
Sub test()
Dim xPass As String
xPass = "MyPassword"
ActiveSheet.Protect Password = xPass
ActiveSheet.Unprotect Password = xPass
End Sub

--
Best Regards,

Luke M
*Remember to click "yes" if this post helped you!*


"des-sa" wrote:

please help. is it possible to password protect only one sheet in workbook?
if so, could anyone please help. can i incorporate the script into an
existing macro?
thanks

Reply
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 a sheet with a list on it aneasiertomorrow Excel Discussion (Misc queries) 3 May 11th 07 12:22 AM
Can't use tab after protecting sheet. tonyia Excel Worksheet Functions 0 March 21st 06 03:57 PM
Protecting Sheet purplerayn Excel Worksheet Functions 1 October 21st 05 12:55 AM
Sheet Protecting password Nick Excel Discussion (Misc queries) 1 June 30th 05 12:43 AM
Can't use tab after protecting sheet. snam Excel Discussion (Misc queries) 3 January 21st 05 02:54 PM


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

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

About Us

"It's about Microsoft Excel"