Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Protecting Selected Sheets


I have three sheets Sheet1, 2 & 3. I want to create a script that wil
password protect sheets 2 & 3 only.

Any help will be greatly appreciated.

Nick

--
Nick
-----------------------------------------------------------------------
Nick S's Profile: http://www.excelforum.com/member.php...fo&userid=1651
View this thread: http://www.excelforum.com/showthread.php?threadid=52764

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 7,247
Default Protecting Selected Sheets


Nick,


Worksheets(2).Protect Password:="whatever"
Worksheets(3).Protect Password:="whatever"


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com


"Nick S"
wrote in message
...

I have three sheets Sheet1, 2 & 3. I want to create a script
that will
password protect sheets 2 & 3 only.

Any help will be greatly appreciated.

Nick.


--
Nick S
------------------------------------------------------------------------
Nick S's Profile:
http://www.excelforum.com/member.php...o&userid=16512
View this thread:
http://www.excelforum.com/showthread...hreadid=527642



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 10,124
Default Protecting Selected Sheets

use a loop something like
for each ws in worksheets
if ws.name <"sheet1" then ws.protect.password="joe"
next


--
Don Guillett
SalesAid Software

"Nick S" wrote in
message ...

I have three sheets Sheet1, 2 & 3. I want to create a script that will
password protect sheets 2 & 3 only.

Any help will be greatly appreciated.

Nick.


--
Nick S
------------------------------------------------------------------------
Nick S's Profile:
http://www.excelforum.com/member.php...o&userid=16512
View this thread: http://www.excelforum.com/showthread...hreadid=527642



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 selected cells in a worksheet JED Excel Discussion (Misc queries) 5 August 28th 07 09:24 AM
Protect selected cells without protecting worksheet Kim Poole Excel Discussion (Misc queries) 2 July 12th 07 10:13 PM
Protecting Macro and selected sheets ST Excel Discussion (Misc queries) 1 June 6th 06 03:03 PM
Default cursor/selected cell position after protecting Stilla Excel Worksheet Functions 0 December 8th 05 02:28 PM
Protecting buttons with VB code rather than protecting sheets/books? StargateFanFromWork Excel Programming 2 July 16th 04 04:03 PM


All times are GMT +1. The time now is 07:50 AM.

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"