Click here to Skip to main content
15,908,661 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
hi,
I have a gridview where in Template field,m having a checkbox.
On checkbox checked or unchecked, i want to retrive the selected row values.how can i do it? plz help..
Regards ,
Rajni pal
Posted

1 solution

Well, though your question is not quite clear, I assume it's something like:
You have a grid with checkboxes. At submit of page, you need to get the rows that has it's checkbox checked. For this, try:
1. Use a foreach loop to loop through the grid rows.
2. Per row, find the checkbox using FindControl
3. Check the state of the checkbox found. If it is checked, use it for checked case or else for unchecked one.

Done.
 
Share this answer
 
Comments
rajni 2 26-Aug-10 4:49am    
thanx...

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