开发者

dynamic grid view loses binding when post back occurs?

dynamic grid view loses binding when post back occurs ?

I have a dynamic grid View with template fields and bound fields as columns

for the first page load a开发者_开发知识库ll binding looks fine.values are populated in all columns

when I trigger an event such as selected index changed in Drop downlist present in the column header(inside template field ) the binding are lost and the event is never catched.

how to retain controls when post back occurs and how to resolve this problem ?


Everytime there is a postback you will have to rebind your grid. Hope you are doing this?


I think you should populate the grid in the Page_Load (which is fired on each update) and set this after populating: <gridname>.Databind();

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜