Click here to Skip to main content
15,896,063 members
Please Sign up or sign in to vote.
4.00/5 (1 vote)
Hi,

I have a situation where I am using 2 gridviews each having checkbox to select the row, Now on the selection of a checkbox on first gridview that row gets added on 2nd gridview.

I am doing it by __dopostback on the selection of the checkbox of first gridview and on .cs class I am adding that row on 2nd gridview.

Issues:

1) the check box is not checked on first gridview after postback, Does gridview not maintain a state?

2) on second post back I am not able to get the datasource of second gridview.

Please advise.


Thanks.
Divya
Posted
Updated 26-May-11 8:49am
v2
Comments
rahkan 26-May-11 13:40pm    
need to see the codes, there's no way for anyone to know what's going on just from what you've said so far

1 solution

Only thing I can say based on what you've said, is check where you are creating the gridview... is it in the aspx page, or created in the code-behind? If code-behind, create it in the Page_Init() method to help persist it during postbacks.
 
Share this answer
 

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