Yea, dynamic controls need to be recreated between postbacks. You can use various ways to "recreate" them to their previous state though such as persisting in viewstate, or global cache, then retrieving the persistance info and using it to "restore" the
recreated controls to their previous state. might be a bit of a pain in the butt though for ones nested in a gridview, dunno.
elementsdynamicallyPostback
When the going get's tough, the tough outsource and take a vacation... lol I wish :(
magicmike201...
Contributor
2021 Points
481 Posts
Re: command of dynamically created element's cleans all generated data
Apr 02, 2012 02:52 AM|LINK
Yea, dynamic controls need to be recreated between postbacks. You can use various ways to "recreate" them to their previous state though such as persisting in viewstate, or global cache, then retrieving the persistance info and using it to "restore" the recreated controls to their previous state. might be a bit of a pain in the butt though for ones nested in a gridview, dunno.
elements dynamically Postback