Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4
Default Automatic Password Protect Sheet

I've coded a button to open a file, copy some info from 1 sheet to another,
but i need the button to first unprotect the sheet, then do its copying, then
protect the sheet when finsihed.

i've tried:

Worksheets("Sheet1!").Protect (password)
and hence
WorkSheets("Sheet1!").UnProtect (password)

but it doesnt password protect it, only protects it normally, anyone help
please?
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 22,906
Default Automatic Password Protect Sheet

Sheets("Sheet1").Unprotect Password:="justme"

your code to do things

Sheets("Sheet1").Protect Password:="justme"


Gord Dibben MS Excel MVP

On Wed, 10 Dec 2008 15:22:05 -0800, Lorcan Dene
wrote:

I've coded a button to open a file, copy some info from 1 sheet to another,
but i need the button to first unprotect the sheet, then do its copying, then
protect the sheet when finsihed.

i've tried:

Worksheets("Sheet1!").Protect (password)
and hence
WorkSheets("Sheet1!").UnProtect (password)

but it doesnt password protect it, only protects it normally, anyone help
please?


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
password protect a sheet Joe Excel Discussion (Misc queries) 5 October 27th 08 11:14 PM
protect sheet with password pswanie Excel Programming 2 December 30th 07 05:14 PM
Protect sheet without password? EllenM Excel Discussion (Misc queries) 2 June 21st 07 03:22 PM
Password Protect a Sheet Lynn Excel Discussion (Misc queries) 1 October 27th 06 03:41 PM
Protect Sheet with password through VBA bill_morgan_3333 Excel Programming 2 December 24th 04 04:03 AM


All times are GMT +1. The time now is 11:11 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"