Home All Groups Group Topic Archive Search About
Author
15 Dec 2005 11:25 PM
Jose Rodriguez
This problem is a tricky one. I am working on an application that loads
dynamic user controls into a panel control. We were getting Viewstate errors
when the user clicked refresh. To fix it, I turned off the Enableviewstate
on the Panel. Now my logic to determine if the user control has been loaded
for the first time is broken. How can I detect a first load on a control
without the benefit of VIewstate? any pointers will be appreciated

Jose

Author
16 Dec 2005 7:01 PM
addup
-- quote --
We were getting Viewstate errors when the user clicked refresh.
-- end quote --

what kind of errors?
I've loaded controls dynamically (is that a word?) into various
templated controls without any problems

--addup--
Author
16 Dec 2005 7:12 PM
Jose Rodriguez
The error I am getting is as follows, I thought I was sure that the control
tree looked exactly the way it was supposed to, but the problem still
occurs. If you have any insights, they'd be appreciated

"Failed to load viewstate. The control tree into which viewstate is being
loaded must match the control tree that was used to save viewstate during
the previous request. For example, when adding controls dynamically, the
controls added during a post-back must match the type and position of the
controls added during the initial request..."
Show quoteHide quote
"addup" <adi.***@gmail.com> wrote in message
news:1134759682.032553.40700@f14g2000cwb.googlegroups.com...
> -- quote --
> We were getting Viewstate errors when the user clicked refresh.
> -- end quote --
>
> what kind of errors?
> I've loaded controls dynamically (is that a word?) into various
> templated controls without any problems
>
> --addup--
>