Vikas Singh

Vikas Singh

  • 1.2k
  • 391
  • 13.5k

I have a checkboxlist and i want to select multiple on binddata

Dec 1 2020 5:16 AM
Hello sir i have a checkboxlist and after save value in db. i want to bind data for edit, I have a value in data table column like '12586,85696,25478,36982' now
 
I want to select multiple checkboxlist item
 
this is code -
  1. List<string> stringempcpf = dtQuery.Rows[0]["CPF"].ToString().Split(',').ToList();  
  2. foreach (string strcpf in stringempcpf)  
  3. {  
  4. if (strcpf != "")  
  5. {  
  6. chkemployee.SelectedValue = strcpf;  
  7. }  
  8. }  
This is checkboxlist
 
 

Answers (4)