AZIQN
02-26-2009, 09:17 AM
Hi, I'm wondering how to combine IF statement criteria in a DO LOOP so I can eliminate unnecessary lines of repetitive loops...here is what I have so far:
Range("K1").Select
Do Until Selection.Value = ""
If Selection.Value = "INVEST ACCOUNT CREDIT" Then
Selection.EntireRow.Delete
Else
Selection.Offset(1, 0).Select
End If
Loop
Range("K1").Select
Do Until Selection.Value = ""
If Selection.Value = "INTEREST CREDIT" Then
Selection.EntireRow.Delete
Else
Selection.Offset(1, 0).Select
End If
Loop
Range("K1").Select
Do Until Selection.Value = ""
If Selection.Value = "INVEST ACCOUNT DEBIT" Then
Selection.EntireRow.Delete
Else
Selection.Offset(1, 0).Select
End If
Loop
Range("K1").Select
Do Until Selection.Value = ""
If Selection.Value = "CONTROLLED DISBURSEMENT DEBIT" Then
Selection.EntireRow.Delete
Else
Selection.Offset(1, 0).Select
End If
Loop
Thanks for your help!
Range("K1").Select
Do Until Selection.Value = ""
If Selection.Value = "INVEST ACCOUNT CREDIT" Then
Selection.EntireRow.Delete
Else
Selection.Offset(1, 0).Select
End If
Loop
Range("K1").Select
Do Until Selection.Value = ""
If Selection.Value = "INTEREST CREDIT" Then
Selection.EntireRow.Delete
Else
Selection.Offset(1, 0).Select
End If
Loop
Range("K1").Select
Do Until Selection.Value = ""
If Selection.Value = "INVEST ACCOUNT DEBIT" Then
Selection.EntireRow.Delete
Else
Selection.Offset(1, 0).Select
End If
Loop
Range("K1").Select
Do Until Selection.Value = ""
If Selection.Value = "CONTROLLED DISBURSEMENT DEBIT" Then
Selection.EntireRow.Delete
Else
Selection.Offset(1, 0).Select
End If
Loop
Thanks for your help!