Exit sub
11.10.2004 18:54:59
Erich
wer kann mir bei meinen Problem weiterhelfen, ich möchte das der nachfolgende code nach dem der Focus in die Combobox gesetzt wurde abgebrochen wird (Exit sub ?) verzweifle daran
für eure hilfe wäre ich sehr dankbar.
gruß
erich
Private Sub CommandButton1_Click()
For i = 1 To 90
If Me.Controls("ComboBox" & i).Value = "" Then
If Me.Controls("ComboBox" & i).Visible = True Then
MsgBox "Alle Felder Ausfüllen!"
Me.Controls("ComboBox" & i).SetFocus
Exit For
End If
End If
Next
Dim intIndex As Integer
With Sheets("E_87")
lz = .Cells(65536, 1).End(xlUp).Row + 1
For intIndex = 1 To 4
.Cells(lz, intIndex) = Controls("TextBox" & CStr(intIndex)).Value
Next intIndex
For intIndex = 1 To 90
.Cells(lz, intIndex + 4) = Controls("ComboBox" & CStr(intIndex)).Value
Next intIndex
End With
End Sub