#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 78
Default Lock formula cells?

Hello,
I'm designing a spreadsheet for my office. Is there a way to prevent my
folks from entering in data into cells with formulas?

Thanks in advance,
Ellen
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3,268
Default Lock formula cells?

You can select all cells in the worksheet, then do formatcellsprotections
and check unlocked, then with all cells still selected press F5, then
special and select formulas, click OK and do formatcellsprotection and
select locked, finally protect the sheet under toolsprotection. It won't
protect it from the most computer savvy that can Google for password
breakers


--
Regards,

Peo Sjoblom



"EllenM" wrote in message
...
Hello,
I'm designing a spreadsheet for my office. Is there a way to prevent my
folks from entering in data into cells with formulas?

Thanks in advance,
Ellen



  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 78
Default Lock formula cells?

Hi Gary,
Thanks for your help.

I'd like for only the cells with formulas to be locked. When did as you
outlined the entire sheet was locked. Did I miss something?

Thanks,
Ellen

"Gary''s Student" wrote:

1. unprotect the sheet
2. unlock all cells
3. Edit Goto Special Formulae
4. Format Cells... Protection Locked
5. protect the sheet

To automate this, use this macro:

Sub Macro2()
ActiveSheet.Unprotect
Cells.Select
Selection.Locked = False
Selection.FormulaHidden = False
Selection.SpecialCells(xlCellTypeFormulas, 23).Select
Selection.Locked = True
ActiveSheet.Protect Contents:=True
ActiveSheet.EnableSelection = xlSelection

End Sub

--
Gary''s Student - gsnu200731


"EllenM" wrote:

Hello,
I'm designing a spreadsheet for my office. Is there a way to prevent my
folks from entering in data into cells with formulas?

Thanks in advance,
Ellen

  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,058
Default Lock formula cells?

Hi Ellen

After step 3, the only cells selected should be formula cells
Step 4 should then lock only those formula cells
Step 5 should activate the locks
--
Gary''s Student - gsnu200731


"EllenM" wrote:

Hi Gary,
Thanks for your help.

I'd like for only the cells with formulas to be locked. When did as you
outlined the entire sheet was locked. Did I miss something?

Thanks,
Ellen

"Gary''s Student" wrote:

1. unprotect the sheet
2. unlock all cells
3. Edit Goto Special Formulae
4. Format Cells... Protection Locked
5. protect the sheet

To automate this, use this macro:

Sub Macro2()
ActiveSheet.Unprotect
Cells.Select
Selection.Locked = False
Selection.FormulaHidden = False
Selection.SpecialCells(xlCellTypeFormulas, 23).Select
Selection.Locked = True
ActiveSheet.Protect Contents:=True
ActiveSheet.EnableSelection = xlSelection

End Sub

--
Gary''s Student - gsnu200731


"EllenM" wrote:

Hello,
I'm designing a spreadsheet for my office. Is there a way to prevent my
folks from entering in data into cells with formulas?

Thanks in advance,
Ellen

  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,058
Default Lock formula cells?

1. unprotect the sheet
2. unlock all cells
3. Edit Goto Special Formulae
4. Format Cells... Protection Locked
5. protect the sheet

To automate this, use this macro:

Sub Macro2()
ActiveSheet.Unprotect
Cells.Select
Selection.Locked = False
Selection.FormulaHidden = False
Selection.SpecialCells(xlCellTypeFormulas, 23).Select
Selection.Locked = True
ActiveSheet.Protect Contents:=True
ActiveSheet.EnableSelection = xlSelection

End Sub

--
Gary''s Student - gsnu200731


"EllenM" wrote:

Hello,
I'm designing a spreadsheet for my office. Is there a way to prevent my
folks from entering in data into cells with formulas?

Thanks in advance,
Ellen



  #6   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 78
Default Lock formula cells?

Hi Gary's Student,
Your script works beautifully. Looks like I need some work to protect
formulas cells by hand.

Thanks so much!!

Ellen

"Gary''s Student" wrote:

1. unprotect the sheet
2. unlock all cells
3. Edit Goto Special Formulae
4. Format Cells... Protection Locked
5. protect the sheet

To automate this, use this macro:

Sub Macro2()
ActiveSheet.Unprotect
Cells.Select
Selection.Locked = False
Selection.FormulaHidden = False
Selection.SpecialCells(xlCellTypeFormulas, 23).Select
Selection.Locked = True
ActiveSheet.Protect Contents:=True
ActiveSheet.EnableSelection = xlSelection

End Sub

--
Gary''s Student - gsnu200731


"EllenM" wrote:

Hello,
I'm designing a spreadsheet for my office. Is there a way to prevent my
folks from entering in data into cells with formulas?

Thanks in advance,
Ellen

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
why do some cells not lock? CDecuir Excel Discussion (Misc queries) 1 April 16th 07 08:31 PM
lock cells. Miri Excel Discussion (Misc queries) 1 February 21st 07 09:42 AM
How lock just some cells Cowtoon New Users to Excel 2 September 29th 06 11:21 PM
how can I lock certain cells? Linds Excel Discussion (Misc queries) 2 December 20th 05 10:46 PM
Lock Cells Diana Excel Discussion (Misc queries) 2 September 26th 05 07:27 PM


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