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

I have a question that I hope that someone can help me with
I have a spreadsheet A that is locked except for cells A1:A10
Cells A1:A10 are data entry cells

I have a spreadsheet B that is protected

I would like to write a macro that copies the values of Cells A1:10 from speadsheet A, unlock speadsheet B, an
then copy the value of cells A1:A10 into cells A1:A10 spreadsheet B
Then I would like to relock Spreadsheet B
I do not know if this is possible, but I would appreciate any help that someone could give. thanks
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 79
Default UnlockProtectedCells

Sheets("B").Activate
ActiveSheet.Unprotect password:="password"
Sheets("A").Activate
Range("A1:A10").Copy
Sheets("B").Select
Range("A65536").End(xlUp).Offset(1,0).Select
ActiveSheet.Paste

HTH, Greg

"Mike" wrote in message
...
I have a question that I hope that someone can help me with.
I have a spreadsheet A that is locked except for cells A1:A10.
Cells A1:A10 are data entry cells.

I have a spreadsheet B that is protected.

I would like to write a macro that copies the values of Cells A1:10 from

speadsheet A, unlock speadsheet B, and
then copy the value of cells A1:A10 into cells A1:A10 spreadsheet B.
Then I would like to relock Spreadsheet B.
I do not know if this is possible, but I would appreciate any help that

someone could give. thanks


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 216
Default UnlockProtectedCells

Gre
Thanks for the help
Mik

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



All times are GMT +1. The time now is 04:22 AM.

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"