Jump to content
Xtreme .Net Talk

Recommended Posts

  • *Experts*
Posted

You can use a For Each loop to go through all the checkboxes.

 

Dim tmp As Checkbox

For each tmp in GroupBox1.Controls
 If tmp.Checked Then
   'code
 End If
Next

  • *Experts*
Posted
Ok, then try something like this:
Dim tmp As Controls

For Each tmp in Me.Controls
 If TypeOf tmp is CheckBox Then
   If DirectCast(tmp, CheckBox).Checked Then
     'code
   End If
 End If
Next

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...