Link to home
Start Free TrialLog in
Avatar of cbrune
cbrune

asked on

how to make a dymanic checkboxes in c# asp.net

how to make a dymanic checkboxes in c# asp.net such as if i want a for loop of 10 checkboxes on the page.
Avatar of ramkihardy
ramkihardy

use check box list to add 10 checkboxes dynamically,
then use this code to find the checkbox which is selected..
foreach(ListItem item in CheckBoxList1.Items)
            if (item.Selected)
            {
                //Do any action
            }
if you create checkboxes it is hard to find which is selected instead of checkboxlist....
Avatar of cbrune

ASKER

can you give me more code then this? sorry im a beginner at asp.net
could you please tell me from where you want to load the values for those checkboxes
ASKER CERTIFIED SOLUTION
Avatar of ramkihardy
ramkihardy

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial