Ausführung des Codes verhindern
08.03.2004 09:15:50
Burkhard
Wie läßt sich verhindern, dass der Code unter "End if" ausgeführ wird? Im Moment erscheint nur die MsgBox, der Code wird ausgeführt. Genau das soll vermieden werden. Danke für Eure Hilfe.
Private Sub CommandButton4_Click()
Dim C As Range
Set C = Tabelle1.Range("C:C").Find(TextBox3, LookAt:=xlWhole)
If Not C Is Nothing Then
MsgBox "Satz schon vorhanden..."
End If
Tabelle1.Select
z = Range("A1").End(xlDown).Row + 1
If z > 65000 Then z = 2
Do While Cells(z, 1) <> ""
z = z + 1
Loop
Cells(z, 1) = TextBox1
Cells(z, 1) = CDbl(TextBox1)
Cells(z, 2) = TextBox2
Cells(z, 3) = TextBox3
Cells(z, 3) = CDbl(TextBox3)
'und so weiter
End Sub