Option
Explicit
Private
Sub
CommandButton1_Click()
Dim
objParentControl
As
MSForms.Control, objChildControl
As
MSForms.Control
For
Each
objParentControl
In
Controls
If
TypeOf
objParentControl
Is
MSForms.Frame
Then
With
objParentControl
For
Each
objChildControl
In
.Controls
If
TypeOf
objChildControl
Is
MSForms.OptionButton
Then
_
If
objChildControl.Value
Then
Exit
For
Next
If
objChildControl
Is
Nothing
Then
Call
MsgBox(
"Eingabe in mind. einem der Frames ('"
& _
.Name &
"') fehlt."
, vbExclamation)
Exit
For
End
If
End
With
End
If
Next
Set
objParentControl =
Nothing
Set
objChildControl =
Nothing
End
Sub