Schleife
17.08.2004 20:50:51
Nenesis
Ich bekomme die if schleife nicht hin
Ich möchte das wen ich auf OptionButton4 clicke
Sich eine input box öffnet und den Wert, den ich da eingebe
Soll in Tabellen Blatt 1 in eine Zelle kopiert werden
das klappt auch
Sollte ich aber auf OptionButton3 clicken, soll in das
Tabellen blatt 1 0 kopiert werden
Mein Code
Private Sub CommandButton2_Click()
Dim Loletztt As Long
Dim vValue As Variant
Dim eValue As Variant
With Worksheets("Tabelle1")
If OptionButton4.Value = True Then
vValue = Application.InputBox( _
prompt:="Teile Nicht in Ordnung ", _
Title:="", _
Type:=1)
eValue = TextBox3 - vValue
If OptionButton3.Value = True Then eValue = 0
Loletztt = .UsedRange.SpecialCells(xlCellTypeLastCell).Row + 1
.Cells(Loletztt, 8) = TextBox5
.Cells(Loletztt, 3) = TextBox3
.Cells(Loletztt, 4).Value = vValue
.Cells(Loletztt, 6) = TextBox4
.Cells(Loletztt, 7) = TextBox6
.Cells(Loletztt, 1) = ComboBox3
.Cells(Loletztt, 2) = ComboBox2
.Cells(Loletztt, 5).Value = eValue
End If
End With
End Sub
Gruß
Nenesis