Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 3
Default How to clear content from unprotected Field

Is there any way to clear unprotected content from the sheet that also
contains formulas in protected fields quickly rather than going column
by column and delete unprotected data?

Thanks for any help that you can provide..

  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 22,906
Default How to clear content from unprotected Field

One way is with a macro.

Sub UnlockedCells()
Dim wk As Worksheet
Dim cl As Range
For Each cl In wk.UsedRange
If cl.Locked = False Then
cl.ClearContents
End If
Next
Next
End Sub

This assumes that you have sheet protection set with option "select unlocked
cells" checked.


Gord Dibben MS Excel MVP

On 11 Nov 2006 07:05:48 -0800, "Amean1" wrote:

Is there any way to clear unprotected content from the sheet that also
contains formulas in protected fields quickly rather than going column
by column and delete unprotected data?

Thanks for any help that you can provide..


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
Use the Merge & Center Button with unprotected Cells - sheet prote Dennis Cantellops Setting up and Configuration of Excel 1 September 22nd 06 12:49 AM
Changing a text field to a date field juliet New Users to Excel 4 February 21st 06 09:52 PM
Stop text from stringing into next field when empty NothingButRomance Excel Worksheet Functions 7 May 17th 05 02:22 AM
Stop text from stringing into next field when empty NothingButRomance Excel Worksheet Functions 2 May 15th 05 05:32 PM
How do I clear cell content when excel document is closed? m3155 Excel Worksheet Functions 1 February 25th 05 11:23 AM


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