ComboBox
27.08.2003 18:04:34
Andreas
Ich möchte mit einer ComboBox eine UserForm öffnen.Es soll aber eine Uhrzeit überprüft werden. Wenn von 6 - 18 Uhr dann soll bei Auswahl z.b Brand eine UserformTag geöffnet werden von 18 -6 Uhr eine UserformNacht.
Die Uhrzeit wird in eine Textbox eingetragen.
Folgenden Code habe ich aber er geht nicht richtig
Private Sub ComboBox1_Change()
If ComboBox = "Atemschutz" And _
CDate(TextBox8.Value) < 0.75 And _
CDate(TextBox8.Value) > 0.249 Then UserForm17.Show
If CDate(TextBox8.Value) > 0.75 And _
CDate(TextBox8.Value) < 0.249 Then UserForm17.Show
If ComboBox1 = "Atemschutz Amtshilfe" And _
CDate(TextBox8.Value) < 0.75 And _
CDate(TextBox8.Value) > 0.249 Then UserForm17.Show
If CDate(TextBox8.Value) > 0.75 And _
CDate(TextBox8.Value) < 0.249 Then UserForm17.Show
Kann mir jemand helfen.
Gruß Andreas