praveenuni
asked on
Dynamic CheckBoxes
Hello,
I 'm creating checkboxes dynamically like this:
foreach (string Name in this.NameList)
{
CheckBox oCheckBox = new CheckBox();
oCheckBox.Text = Name;
oCheckBox.AutoPostBack = true;
oCheckBox.CheckedChanged +=new EventHandler(oCheckBox_Che ckedChange d);
this.LayersPanel.Controls. Add(oCheck Box);
}
This will create checkboxes list = count of names in the arraylist.
Problem: If I select first checkbox, it should automatically select all other checkboxes in the list. But not the same case if I select any other checkbox. How can I do this?
I 'm creating checkboxes dynamically like this:
foreach (string Name in this.NameList)
{
CheckBox oCheckBox = new CheckBox();
oCheckBox.Text = Name;
oCheckBox.AutoPostBack = true;
oCheckBox.CheckedChanged +=new EventHandler(oCheckBox_Che
this.LayersPanel.Controls.
}
This will create checkboxes list = count of names in the arraylist.
Problem: If I select first checkbox, it should automatically select all other checkboxes in the list. But not the same case if I select any other checkbox. How can I do this?
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.