Error in gridview chekbox....rectify

Posted by Oswaldlily under ASP.NET on 5/29/2012 | Points: 10 | Views : 715 | Status : [Member] | Replies : 1
I have gridview1 with checkbox column present

checked row in gridview1 should display corresponding details
in gridview2

by using lik this continued...
foreach(GridViewRow g in gv.Rows)
{
CheckBox chkbxx = (CheckBox)g.FindControl("chkSelect");
var value=....
if(chkbxx.checked==true)
{
gv.datasource=value;
gv.databind();
}
}

if i checked 3 rows ,this ll loop inside this foreach and displaying oly the 3rd row details.
Means last records alone displaying.
First two checked detials not showin..why?




Responses

Posted by: Lacy on: 5/30/2012 [Member] Starter | Points: 25

Up
0
Down
I do not know your case clearly, and you can find another way to deal with it.

http://www.e-iceblue.com/Knowledgebase/Spire.PDF/Demos/Grid.html#twoj_fragment1-2

Oswaldlily, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response