Sub Active_sheet()
' copy_Active RAP to other sheet
Set i = Sheets("PO_Status")
Set e = Sheets("Active_sheet")
Dim d, j As Integer
d = 1
j = 2
Do Until IsEmpty(i.Range("F" & j))
If i.Range("F" & j) = "Active" Then
If InStr(1, i.Range("D" & j).Value, "Network") > 0 Or InStr(1, i.Range("D" & j).Value, "server") > 0 Or InStr(1, i.Range("D" & j).Value, "Rack") > 0 Then
d = d + 1
e.Rows(d).Value = i.Rows(j).Value
i.Select
Rows(j).Copy
e.Select
Rows(d).PasteSpecial
End If
End If
j = j + 1
Loop
End Sub
Don't think you can use OR the way you are using it
also INSTR function as you are not doing exact match
if string exist it would give a number so if number is greater than 0 then if loop is executed
i separated your "active" loop so make it easier to follow
Bookmarks