Click here to Skip to main content
15,892,965 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
If TypeOf CControl Is CheckBox = True Then
if ccontrol.checkedstate = true then
'function
end if
end if

What I have tried:

how do i check property of every checkbox in the form?
and prefrom function on finding value true
Posted
Updated 12-Jul-18 11:24am
v2

1 solution

Assuming you are referring to a WinForms form then you need to query the Controls Collection for the form - here is how How to: Access Controls by using the Controls Collection[^] - principle applies to ASP.net too

If you are using WPF then read this[^] instead
 
Share this answer
 
Comments
Maciej Los 12-Jul-18 15:15pm    
5ed!

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900