For
Anzahl = 1
To
AnzahlTB
For
zeile = ZeileMax
To
1
Step
-1
If
.Cells(zeile, 1).value = UserForm2.ComboBox1.value
Then
If
.Cells(zeile, 13).value = UserForm2.ComboBox4.value
Then
Anzahl = Anzahl + 1
.Rows(zeile).Delete
End
If
Else
f = MsgBox(
"Durchsuche Zeile: "
& zeile & Chr(13) & .Cells(zeile, 1).value & .Cells(zeile, 13).value & Chr(13) & UserForm2.ComboBox1.value & UserForm2.ComboBox4.value, vbOKOnly,
"Info"
)
End
If
If
Anzahl = AnzahlTB
Then
Exit
For
If
zeile = 1
Then
i = MsgBox(
"BLAAAAA"
, vbCritical,
"Error!"
)
If
i = vbOK
Then
Exit
Sub
Next
zeile
Next
Anzahl