I have several frames on a form, each containing numerous checkboxes. Is there an easy way to check or uncheck all the checkboxes on a particular frame short of coding each checkbox value?
Printable View
I have several frames on a form, each containing numerous checkboxes. Is there an easy way to check or uncheck all the checkboxes on a particular frame short of coding each checkbox value?
VB Code:
Private Sub ClearCheckBoxesOnFrame(fra As Frame) Dim c As Control For Each c In Me.Controls If LCase$(TypeName(c)) = "checkbox" Then If c.Container Is fra Then c.Value = vbUnchecked End If End If Next End Sub 'usage ClearCheckBoxesOnFrame Frame1
crptcblade,
Thanks, that did the trick.
Michael