John Davis
Well-known Member
- Joined
- Sep 11, 2007
- Messages
- 3,457
Hello All:
The below code is not accomplishing the task. It should delete all the rows in Column K which contain the word DUAL. Can anyone offer any help? Could this be a formating issue?
Dim lastrow As Long, myrow As Long
lastrow = Cells(Rows.Count, 11).End(xlUp).Row
For myrow = lastrow To 2 Step -1
If Cells(myrow, 11).VALUE = "DUAL" Then Rows(myrow).DELETE
Next myrow
The below code is not accomplishing the task. It should delete all the rows in Column K which contain the word DUAL. Can anyone offer any help? Could this be a formating issue?
Dim lastrow As Long, myrow As Long
lastrow = Cells(Rows.Count, 11).End(xlUp).Row
For myrow = lastrow To 2 Step -1
If Cells(myrow, 11).VALUE = "DUAL" Then Rows(myrow).DELETE
Next myrow