Hi
See how this goes
Sub aaa()
Sheets("Data Raw").Select
Range("A1:L1").Value = Array("H1", "H2", "H3", "H4", "H5", "H6", "H7", "H8", "H9", "H10", "H11", "H12")
Rows("2:4").Delete
arr = Array("IDD", "CAT", "ACE", "ACT", "ZZZ")
For i = LBound(arr) To UBound(arr)
Range("A:L").AutoFilter field:=1, Criteria1:=arr(i)
Range("A2:A" & Cells(Rows.Count, 1).End(xlUp).Row).SpecialCells(xlCellTypeVisible).EntireRow.Delete
Next i
ActiveSheet.ShowAllData
ActiveSheet.AutoFilterMode = False
For i = 2 To Cells(Rows.Count, 1).End(xlUp).Row
If Cells(i, 1) = "SP8" Then
holder = Cells(i, 2).Value
Else
Cells(i, 1).Value = holder & Cells(i, 2).Value
Cells(i, 3).Value = holder
End If
Next i
Range("A:L").AutoFilter field:=1, Criteria1:="SP8"
Range("A2:A" & Cells(Rows.Count, 1).End(xlUp).Row).SpecialCells(xlCellTypeVisible).EntireRow.Delete
ActiveSheet.AutoFilterMode = False
Rows("1:1").Delete
Range("A:L").Sort key1:=Range("A1"), order1:=xlAscending
End Sub
rylo
Bookmarks