Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have the following code that should delete any row that doesn't have the
value of Defective in my range but it is deleting everything. Please help. lastrow = Cells(Rows.Count, "A").End(xlUp).Row For Each c In ActiveSheet.Range("C2:C" & lastrow) If c.Value = "DEFECTIVE" Then Else Selection.EntireRow.delete End If Next Thanks in advance, Aaron |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Macro to delete sheets and saves remaining file does not properly delete module | Excel Programming | |||
Macro to delete sheets and saves remaining file does not properly delete module | Excel Programming | |||
Macro to delete sheets and saves remaining file does not properly delete module | Excel Programming | |||
Macro to delete sheets and saves remaining file does not properly delete module | Excel Programming | |||
Delete every 3rd row, then delete rows 2-7, move info f/every 2nd row up one to the end and delete the row below | Excel Programming |