M
Matt
I'm using this code to delete all the rows that have "RG" in the A
column. It should run through the entire range A1:A50 when I click a
userform button. But instead of deleting them all with one click, its
just deleting one of the "RG" rows each time I click the button (or
even a few of the rows, but not all). Can anyone help?
Private Sub RunReport_Click()
For Each dept In Range("A1:A50")
If dept.Value = "RG" Then
Rows(dept.Row).Delete
End If
Next dept
End Sub
column. It should run through the entire range A1:A50 when I click a
userform button. But instead of deleting them all with one click, its
just deleting one of the "RG" rows each time I click the button (or
even a few of the rows, but not all). Can anyone help?
Private Sub RunReport_Click()
For Each dept In Range("A1:A50")
If dept.Value = "RG" Then
Rows(dept.Row).Delete
End If
Next dept
End Sub