View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Bob Phillips Bob Phillips is offline
external usenet poster
 
Posts: 10,593
Default Search a range to find cells containing formulas

For Each Cell In Activesheet.UsedRange
cell.Locked = Not cell.Hasformula
Next cell

Activesheet.Protect

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)

"tanktata" wrote in
message ...

I am trying to create a macro that will search through a range and
protect any cells that contain formulas of any type.

Can anyone help?

Thanks.


--
tanktata
------------------------------------------------------------------------
tanktata's Profile:

http://www.excelforum.com/member.php...fo&userid=4598
View this thread: http://www.excelforum.com/showthread...hreadid=559103