Re: Datalist Dynamic Template Loading Problem

Tech-Archive recommends: Fix windows errors by optimizing your registry



1)If I only assign these templates if its not a post back, the
datalist is blank when I click on the edit button in the datalist.

You need to recreate any and all dynamic controls upon every postback. You typically do this inside of CreateChildControls (a virtual from the Control base class). If you recreate the controls properly, then it will behave as if they were done statically in the ASPX file.


-Brock
DevelopMentor
http://staff.develop.com/ballen




.


Quantcast