Click here to Skip to main content
14,983,344 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
XML
I have two checkboxes like :

<div>
    <asp:CheckBox ID="CheckBox1" runat="server" Checked="true" Text="Status"/>
    </div>
    <div>
    <asp:CheckBox ID="CheckBox2" runat="server" Checked="true" Text="FirstName"/>
    </div>

I have an array like

string[] arrchk = new string[] { };

How can I store the text value of the checkboxes in the array
Posted
Comments
Sunasara Imdadhusen 28-Apr-14 7:50am
   
Need more clarification for the same.
Sanket Saxena 28-Apr-14 7:55am
   
On Which event you want to push the data into array?
Sivaraman Dhamodharan 28-Apr-14 8:43am
   
Is there any submit button on the form?

1 solution

Convert the boolean value i.e. true or false to 'Y' or 'N' and then store it in the array.
   

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