Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Deletion of rows according to background color
I have an excelsheet wherby rows having different
background colors. How can i select certain background color and delet the remaining. Thanks |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Deletion of rows according to background color
Salim,
You could do it this way write a UDF to determine the ColoIndex of a cell in the adjacent column, use the UDF to get the Colorindex filter on this column select not equal to hour value Delet visible rows -- HTH Bob Phillips ... looking out across Poole Harbour to the Purbecks (remove nothere from the email address if mailing direct) "salim" wrote in message ... I have an excelsheet wherby rows having different background colors. How can i select certain background color and delet the remaining. Thanks |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Deletion of rows according to background color
To Me it looks like headlines can you please elaborate
Thanks -----Original Message----- Salim, You could do it this way write a UDF to determine the ColoIndex of a cell in the adjacent column, use the UDF to get the Colorindex filter on this column select not equal to hour value Delet visible rows -- HTH Bob Phillips ... looking out across Poole Harbour to the Purbecks (remove nothere from the email address if mailing direct) "salim" wrote in message ... I have an excelsheet wherby rows having different background colors. How can i select certain background color and delet the remaining. Thanks . |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Deletion of rows according to background color
Here is an additional approach:
assume the colors are at least in column A Sub DeleteColor() Dim rng As Range, LastRow As Long Dim i As Long Set rng = ActiveSheet.UsedRange.Columns(1).Cells LastRow = rng(rng.Count).Row For i = LastRow To 1 Step -1 idex = Cells(i, 1).Interior.ColorIndex Select Case idex Case 3, 8, 9, 21 Cells(i, 1).EntireRow.Delete End Select Next End Sub -- Regards, Tom Ogilvy wrote in message ... To Me it looks like headlines can you please elaborate Thanks -----Original Message----- Salim, You could do it this way write a UDF to determine the ColoIndex of a cell in the adjacent column, use the UDF to get the Colorindex filter on this column select not equal to hour value Delet visible rows -- HTH Bob Phillips ... looking out across Poole Harbour to the Purbecks (remove nothere from the email address if mailing direct) "salim" wrote in message ... I have an excelsheet wherby rows having different background colors. How can i select certain background color and delet the remaining. Thanks . |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
find excel rows with a background color | Excel Discussion (Misc queries) | |||
Default Border, Font Color, and Cell Background Color | Excel Discussion (Misc queries) | |||
can you select rows in excel with a certain background color? | Excel Worksheet Functions | |||
Identify rows with certain background color? | Excel Programming | |||
Background color for 50,000 odd-numbered rows | Excel Programming |