OptionButton zur Auswahl
06.08.2008 18:22:39
Peter
ich habe da mal eine Frage und bitte um Hilfe
ich habe eine Userform wo eine combobox6 mit daten gefüllt ist.
wähle ich eine Datensatz aus so bekomme ich einen wert in einem Textfeld3 und Textfeld19
zurückgegeben.
jetzt möchte ich mit 2 OptionButton anklicken welches textfeld (3 oder 19 ) seinen Wert an das Textfeld 7
weitergibt.
Bisher hatte ich nur ein Textfeld so das keine Auswahl nötig war
Danke vorab für die Hilfe
Gruß Peter
Hier die werte für die Combobox und dazu der wert für das textfeld:
Private Sub ComboBox6_Change()
'Kategorie 20
If ComboBox6 = 5000 Then TextBox3.Value = CCur(130)
If ComboBox6 = 7000 Then TextBox3.Value = CCur(155)
If ComboBox6 = 9000 Then TextBox3.Value = CCur(165)
If ComboBox6 = 11000 Then TextBox3.Value = CCur(175)
If ComboBox6 = 13000 Then TextBox3.Value = CCur(205)
If ComboBox6 = 15000 Then TextBox3.Value = CCur(215)
If ComboBox6 = 17000 Then TextBox3.Value = CCur(250)
If ComboBox6 = 19000 Then TextBox3.Value = CCur(260)
If ComboBox6 = 21000 Then TextBox3.Value = CCur(275)
If ComboBox6 = 23000 Then TextBox3.Value = CCur(310)
If ComboBox6 = 25000 Then TextBox3.Value = CCur(325)
'Kategorie 25
If ComboBox6 = 5000 Then TextBox19.Value = CCur(180)
If ComboBox6 = 7000 Then TextBox19.Value = CCur(210)
If ComboBox6 = 9000 Then TextBox19.Value = CCur(220)
If ComboBox6 = 11000 Then TextBox19.Value = CCur(230)
If ComboBox6 = 13000 Then TextBox19.Value = CCur(260)
If ComboBox6 = 15000 Then TextBox19.Value = CCur(270)
If ComboBox6 = 17000 Then TextBox19.Value = CCur(305)
If ComboBox6 = 19000 Then TextBox19.Value = CCur(315)
If ComboBox6 = 21000 Then TextBox19.Value = CCur(330)
If ComboBox6 = 23000 Then TextBox19.Value = CCur(365)
If ComboBox6 = 25000 Then TextBox19.Value = CCur(375)
If ComboBox6 "" Then TextBox7.Value = CCur(ComboBox6)
Dim a As Long, b As Long
a = CCur(TextBox3)
TextBox7 = TextBox3
End Sub