Ok, I have a control that loads child controls, the children hold logic that
executes during a postback. Since the child is loaded by the time when it's
events fire, I need to be able to clear all loaded children (from the
original parent) and restart the load process.
A sample postback:
1. Parent Loads
2. Chilid Loads
3. Child event fires
4. Child changes "State" variable = a different child
5. Postback stops, and restarts, this time loading a different child
I almost made it work by using an object with a StateChanged event, and then
in the event handler I called ClearChildViewstate & Children.Clear and
reloaded. But it only works once, after that it throws an exception about
the view state.
Any help will be greatly appreciated.
Thanks,
Jeremy