USER FORM THAT PRINTS OUT SELECTED CHOICES

insert  USER FORM -  frmEingabeMaske.Show

Private Sub fraBahnCard_Click()

End Sub

Private Sub UserForm_Initialize()
'Beim Start des Formulars ist ohne Bahr Card ausgewahlt

Me.optOhneBC.Value = True

End Sub
Private Sub cmdAuswertung_Click()

Dim conOptionButtons As MSForms.Control
Dim strAuswahlBC As String
Dim strAuswahlGeschlecht As String

'Untersucht die Optionsschalter bei BahnCard

    For Each conOptionButtons In fraBahnCard.Controls
        If conOptionButtons.Value = True Then
            strAuswahlBC = conOptionButtons.Caption
           
        End If
        Next conOptionButtons
       
        'Untersucht die Optionsschalter bei Geschlecht
        For Each conOptionButtons In fraGeschlecht.Controls
            If conOptionButtons.Value = True Then
           strAuswahlGeschlecht = conOptionButtons.Caption
           
        End If
        Next conOptionButtons
       
        MsgBox "Sie haben " & strAuswahlBC & " für  " & strAuswahlGeschlecht & " gewählt"
       
    Unload Me
   
End Sub


Private Sub optGepaeck_Click()
'By clicking the one cell option button the others are disabled b/C they are not possible

With Me

 .optGepaeck.Value = True
 .optOhneBC.Enabled = False
 .optBC25.Enabled = False
 .optBC50.Enabled = False
 
 End With
 
 
End Sub

Private Sub optMaennlich_Click()

With Me

 .optOhneBC.Enabled = True
 .optBC25.Enabled = True
 .optBC50.Enabled = True
 
 End With
 
End Sub

Private Sub optWeiblich_Click()

With Me

 .optOhneBC.Enabled = True
 .optBC25.Enabled = True
 .optBC50.Enabled = True
 
 End With



End Sub


Insert a MODULE

 

Sub FormualrAufrufe()


 frmEingabeMaske.Show
 
End Sub