-
Why loop? ...
[vba]Sub ProcessData2()
Dim rngFormula As Range
With ActiveSheet
.Columns(1).Insert: .Columns(1).Insert
Set rngFormula = .Range("A2:A" & .Cells(.Rows.Count, "C").End(xlUp).Row)
rngFormula.Formula = "=C2&D2&E2"
rngFormula.Offset(0, 1).Formula = "=COUNTIF($A$2:A2,A2)"
.Cells.AutoFilter field:=2, Criteria1:="=2"
rngFormula.SpecialCells(xlCellTypeVisible).EntireRow.Delete
.Columns(1).Delete: .Columns(1).Delete
.AutoFilterMode = False
End With
End Sub[/vba]
HTH
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules