AW: AW: Speichern der Eingabemaske
26.11.2006 17:06:56
Achille
Es funktionier einfach nicht, ich kriege weiterhin ein Debbug.
hier nochmal die fesamte Formel.
Option Explicit
Private Sub ComboBox1_Click()
If ComboBox1.ListIndex <> 0 Then
TextBox1 = Cells(ComboBox1.ListIndex + 1, 1)
Else
TextBox1 = ""
End If
End Sub
Private Sub CommandButton1_Click()
If ComboBox1.ListIndex > 0 Then
Rows(ComboBox1.ListIndex + 1).Delete
TextBox1 = ""
UserForm_Initialize
End If
End Sub
Private Sub CommandButton2_Click()
Dim xZeile As Long
If TextBox1 = "" Then Exit Sub
If ComboBox1.ListIndex = 0 Then
xZeile = [A65536].End(xlUp).Row + 1
Else
xZeile = ComboBox1.ListIndex + 1
End If
Private Sub CommandButton4_Click()
If TextBox1 = "" Then ActiveWorkbook.Save
End Sub
TextBox1 = ""
Cells(xZeile, 2).Value = TextBox2.Value
Cells(xZeile, 3).Value = TextBox3.Value
Cells(xZeile, 4).Value = TextBox4.Value
Cells(xZeile, 5).Value = TextBox5.Value
Cells(xZeile, 6).Value = TextBox6.Value
Cells(xZeile, 7).Value = TextBox7.Value
Cells(xZeile, 8).Value = TextBox8.Value
Cells(xZeile, 9).Value = TextBox9.Value
Cells(xZeile, 10).Value = TextBox10.Value
Cells(xZeile, 11).Value = TextBox11.Value
Cells(xZeile, 12).Value = TextBox12.Value
Cells(xZeile, 13).Value = TextBox13.Value
TextBox1 = ""
TextBox2 = ""
TextBox3 = ""
TextBox4 = ""
TextBox5 = ""
TextBox6 = ""
TextBox6 = ""
TextBox8 = ""
TextBox9 = ""
TextBox10 = ""
TextBox11 = ""
TextBox12 = ""
TextBox13 = ""
End Sub
Private Sub CommandButton3_Click()
Unload Me
End Sub
Private Sub TextBox121_Change()
End Sub
Private Sub TextBox11_Change()
End Sub
Private Sub TextBox3_Change()
End Sub
Private Sub TextBox6_Change()
End Sub
Private Sub UserForm_Initialize()
Dim aRow, i As Long
Application.EnableEvents = False
ComboBox1.Clear
aRow = [A65536].End(xlUp).Row
ComboBox1.AddItem "neue Person hinzufügen"
For i = 2 To aRow
ComboBox1.AddItem Cells(i, 1) & ", " & Cells(i, 2)
Next i
ComboBox1.ListIndex = 0
Application.EnableEvents = True
End Sub