wagazub
asked on
Microsoft Development NET ASP.NET DataList Dynamic ItemTemplate Controls not firing
I'm new to experts exchange so please forgive protocol errors.
I want to dynamically specify the content of a DataList ItemTemplate. I researched, learnt how to do ITemplate class etc. Still having diffiiculty.Primary issue is that server events for ItemTemplate controls not firing. (Button ID btn in this case.
Code example has 3 files. TemplateTest aspx and cs should be in TemplateTest folder and MovieCollection.cs in App_Code. See aspx
1) DataList1 works fine as expected.
2) Now try to duplicate in DataList2 using code in QPTemplate class. Clicking buttoms does not result in server events firing. DataList2 also is corrupted after server return.
Help much appreciated.
Louis
I want to dynamically specify the content of a DataList ItemTemplate. I researched, learnt how to do ITemplate class etc. Still having diffiiculty.Primary issue is that server events for ItemTemplate controls not firing. (Button ID btn in this case.
Code example has 3 files. TemplateTest aspx and cs should be in TemplateTest folder and MovieCollection.cs in App_Code. See aspx
1) DataList1 works fine as expected.
2) Now try to duplicate in DataList2 using code in QPTemplate class. Clicking buttoms does not result in server events firing. DataList2 also is corrupted after server return.
Help much appreciated.
Louis
See TemplateTest.zip
TemplateTest.zip
ASKER
Points increased
It might be easier if you give me a 1000 meter view, rather than all that detailed information. What kind of errors are you getting? How are you binding the DataList? What kind of page life cycle processing are involved?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
I don't like looking through other people's code, if I don't have to. I believe that the question could have been explained well enough to get an answer without code.
ASKER
Louis
Open in new window