PDA

View Full Version : Solved: Clear all within range



tqm1
06-22-2007, 05:31 AM
Dear Experts

I use following codes to clear data from range("a6") to lastrow


With Sheets("Rpt_Daily")
Range(.Cells(6, 1), .Cells(65536,1).End(xlUp)).EntireRow.ClearContents
End with

But it only clear data, not format.
How to clear Data and Format within given range?

I want to clear (data + borders + color etc)

Please help

Simon Lloyd
06-22-2007, 05:39 AM
With Sheets("Rpt_Daily")
Range(.Cells(6, 1), .Cells(65536,1).End(xlUp)).EntireRow.Clear
End with

Simon Lloyd
06-22-2007, 05:50 AM
tqm1, it's about time you did some work of your own rather than posting other peoples code on different forums!, you were answered at excel forum by the person below!



ska67can (http://www.excelforum.com/member.php?u=45867) http://www.excelforum.com/images/statusicon/user_offline.gif vbmenu_register("postmenu_1794000", true);
Registered User
Join Date: Jan 2007
Posts: 49


Code:


With Sheets("Report-1") Range(.Cells(6, 1), .Cells(65536, 1).End(xlUp)).EntireRow.ClearContents
End With


ska