PDA

View Full Version : Solved: Clearing Column Contents



zoom38
02-25-2006, 09:07 AM
Im trying to write some code to clear the contents and borders of columns A thru g with the exception of the first two rows which I want to remain. I think it is a simple one but I can't figure it out.

Thanks In Advance
Gary

Jacob Hilderbrand
02-25-2006, 09:19 AM
Try this:


With Range("A3:G65536")
.ClearContents
.Borders.LineStyle = xlNone
End With

zoom38
02-25-2006, 09:31 AM
Thanks DRJ, I thought there would have been an easier way using entirecolumn or something like that.
Thanks Again

XLGibbs
02-25-2006, 02:08 PM
Yes, but entirecolumn would not allow retaining the status quo in rows 1 and 2 as you wished.

zoom38
02-25-2006, 06:59 PM
Ok, I thought maybe an exception for the two rows could be made. Thanks guys problem solved. I would mark this thread as solved but I can't find that tool anymore.

XLGibbs
02-25-2006, 07:01 PM
Once the board upgrades are resolved, we will mark it solved for you...the feature is temporarily unavailable.