Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
Nev Nev is offline
external usenet poster
 
Posts: 20
Default UNprotect columns in protected workbook

Some columns in my workbook are locked and some not. I want to be able to
unlock via a macro the selected columns in the active sheet then be able to
lock them after data entry. This wil the macro in Personal.xls

I have looked at previous answers which do not seem to help.

Thanks

Nev
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 8,520
Default UNprotect columns in protected workbook

Try below to unlock selected cells. Please modify if you have a password..

Sub UnLockSelection()
Activesheet.UnProtect
Selection.Locked = False
Activesheet.Protect
End Sub

After data entry (based on which event) you need to again unprotect. Select
all cells..and protect back..

If this post helps click Yes
---------------
Jacob Skaria


"Nev" wrote:

Some columns in my workbook are locked and some not. I want to be able to
unlock via a macro the selected columns in the active sheet then be able to
lock them after data entry. This wil the macro in Personal.xls

I have looked at previous answers which do not seem to help.

Thanks

Nev

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 20
Default UNprotect columns in protected workbook

On Sun, 19 Apr 2009 06:27:03 -0700, Nev
wrote:

Some columns in my workbook are locked and some not. I want to be able to
unlock via a macro the selected columns in the active sheet then be able to
lock them after data entry. This wil the macro in Personal.xls

I have looked at previous answers which do not seem to help.

Thanks

Nev


Turning protection on or off is a manual operation due to the password
requisite.

Perhaps you could lock cells from user access, yet fill the data those
cells contain by way of a separate cell array that the user does have
access to.
  #4   Report Post  
Posted to microsoft.public.excel.programming
Nev Nev is offline
external usenet poster
 
Posts: 20
Default UNprotect columns in protected workbook

Jacob

that's great! I did not think it would be done like this. Because it is, I
see that i can enter new data immediately - is there a way to lock the cell
once the new figure is entered and the enter button is pushed

Thanks

Nev


"Jacob Skaria" wrote:

Try below to unlock selected cells. Please modify if you have a password..

Sub UnLockSelection()
Activesheet.UnProtect
Selection.Locked = False
Activesheet.Protect
End Sub

After data entry (based on which event) you need to again unprotect. Select
all cells..and protect back..

If this post helps click Yes
---------------
Jacob Skaria


"Nev" wrote:

Some columns in my workbook are locked and some not. I want to be able to
unlock via a macro the selected columns in the active sheet then be able to
lock them after data entry. This wil the macro in Personal.xls

I have looked at previous answers which do not seem to help.

Thanks

Nev

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
unprotect (in Excel 2007) workbook created and protected in Excel DonJ_Austin New Users to Excel 7 October 2nd 08 03:49 PM
unprotect a write protected file suzzyq Excel Discussion (Misc queries) 2 June 8th 08 08:22 PM
Excel - unprotect certain cells in protected sheet/workbook ekonomija Excel Discussion (Misc queries) 3 November 21st 07 10:58 PM
Unprotect a protected worksheet Teri Excel Worksheet Functions 2 November 20th 07 10:37 PM
How can I unprotect a worksheet that is password protected Password Excel Discussion (Misc queries) 3 December 30th 04 06:13 PM


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