Q: dynamically created databound controls persist but static controlsdon't

  • Thread starter mad.scientist.jr
  • Start date
M

mad.scientist.jr

I am running into a case where I am databinding a control
(dropdown, checkboxlist, etc) to a datatable,
caching the datatable in session,
and on postback rebind the control.
After postback the control loses its value.
However if I try this with a dynamically created control,
it maintains state just fine.
(I would think it would be the other way around.)

You can cut/paste my aspx and codebehind into your project from here:
http://www.geocities.com/usenet_daughter/databind_persist_issue.htm

How would you get the static control (CheckBoxList1)
to maintain state after postback?
I am curious why this is happening.

Thanks
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,776
Messages
2,569,603
Members
45,188
Latest member
Crypto TaxSoftware

Latest Threads

Top