![]() |
|
#1
|
|||
|
|||
![]() I need to be able to quickly clear data fields on a worksheet. How do I do that? Excel 2010 |
#2
|
|||
|
|||
![]()
if you create a button then unprotect all cells you want to clear then add a macros that when button presses all unprotected cells will clear --- If this will work for you use this macros
Code:
Option Explicit Sub Button1_Click() Dim rClear As Range Dim rCl As Range For Each rCl In ActiveSheet.UsedRange If Not rCl.Locked = True Then If rClear Is Nothing Then Set rClear = rCl Else: Set rClear = Union(rCl, rClear) End If End If Next rCl rClear.ClearContents End Sub |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
sheet 2 data highlight in sheet 1 | gsrikanth | Excel | 1 | 04-21-2012 06:25 PM |
styles ‒ clearing local overrides | eNGiNe | Word | 1 | 03-01-2012 08:15 AM |
![]() |
PRADEEPB270 | Excel | 1 | 11-04-2011 03:46 AM |
copy cell from sheet 2 to sheet 3 macro | slipperyjim | Excel Programming | 1 | 02-18-2010 01:31 AM |