Link to home
Start Free TrialLog in
Avatar of saloj
salojFlag for Canada

asked on

CheckBoxList display from codebehind

HI EE,

I have CheckBoxList for category and when I update the page.
1. I want to get the stored value from DB
2. if the category is already in DB then check on the CheckboxList
3. Display all the category list on CheckBoxList on .aspx page

how can I do the task!!!

[.aspx]
 <asp:CheckBoxList ID="CheckBoxList1" runat="server"></asp:CheckBoxList>
 
 [.cs]
 page_load(){
 //SelectedCategory from DB
 //GetCategory(SelectedCategory)
 //CheckBoxList1 add to .aspx page
 }
 
 GetCategory(SelectedCategory){
 // Display all category
 // compare with SelectedCategory
 // Return values
 }

Thank you
Avatar of Rahul Agarwal
Rahul Agarwal
Flag of India image

ASKER CERTIFIED SOLUTION
Avatar of Anurag Agarwal
Anurag Agarwal
Flag of India image

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