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
<(E-Mail Removed)> 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?
|