Macro-Return Blank Cell

  • Thread starter Thread starter Sudipta Sen
  • Start date Start date
S

Sudipta Sen

I am creating an Invoice by the help of macro where I want to clear all the
data from unlock cell after entering the buttom named NEXT or OK.So I could
enter fresh data in the same unlock cell.

How it possible?

Rdgs...Sudipta
 
Sub setup()
Dim cel As Range, r As Range
For Each r In ActiveSheet.UsedRange
If r.Locked Then
Else
If cel Is Nothing Then
Set cel = r
Else
Set cel = Union(cel, r)
End If
End If
Next

If cel Is Nothing Then
Else
cel.Clear
End If

End Sub
 
Thank Gary for ur co-operation. But actually I want clear content without
disburbing my formula & format from individual cell. means from a2 , c2, a7,
d8 etc.

want to use
clear contents macro for mentioned cell.

With Loves
Sudipta
 
Back
Top