Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Please help me!!
how to delete row where the row is not coloured |
#2
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
On Nov 7, 2:18 pm, wrote:
Please help me!! how to delete row where the row is not coloured Hi Isybel It depends on how and when you want to delete them. Do you want to this procedure once, or more often? I'd say write a function which goes through all rows, look up the interior.color value and delete those who are = xlnone If you need help doing that, just ask. hth Carlo |
#3
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
I think this will give you what you want:
Sub DeleteAllUncolored() Dim ClrRng As Range Set ClrRng = Range("A1", Range("A5000").End(xlUp)) For Each cell In ClrRng If cell.Interior.ColorIndex = xlNone Then cell.EntireRow.Delete End If Next cell End Sub As always, be extremely careful when deleting date; try this macro on a sample before you execute on your actual data. Regards, Ryan-- -- RyGuy "carlo" wrote: On Nov 7, 2:18 pm, wrote: Please help me!! how to delete row where the row is not coloured Hi Isybel It depends on how and when you want to delete them. Do you want to this procedure once, or more often? I'd say write a function which goes through all rows, look up the interior.color value and delete those who are = xlnone If you need help doing that, just ask. hth Carlo |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
delete the test values, but do not delete the formulas | Excel Discussion (Misc queries) | |||
How can I delete a macro when the Delete button is not active? | Excel Worksheet Functions | |||
How to Delete a Range in Closed Workbook (to Replace Delete Query) | Excel Discussion (Misc queries) | |||
How do i delete a macro in Excel 2003 when delete isn't highlight | Excel Discussion (Misc queries) | |||
How to delete rows when List toolbar's "delete" isnt highlighted? | Excel Worksheet Functions |