It has to do with the stage within the page’s lifecycle when you turned the
child controls visible (i.e. created them) and therefore their viewstate was
saved and loaded upon the next postback. Can you post the logic of setting
the controls visible indicating at which stage (at which event handling) do
set them to visible?
--
HTH,
Phillip Williams
http://www.societopia.net
http://www.webswapp.com
"Jon Prisbe" wrote:
> I have a web site with a default page and several user controls on the page
> that get set to visible or invisible dependign on the menu optonthe user
> chooses.
>
> One control has another user control on it (child) and that use control can
> have one or more user controls on it (grand children).
>
> Problem:
> The link buttons on the child and grand children have to be clicked twice
> for the event handler to get called. Order doesn't matter. If I click button1
> first and then button2, button2's event handler gets fired. If I click
> button1 first and then button1 again, button1's event handler gets fired.
> Order doesn't seem to make any difference, acts like the first click cocks
> the gun and the second click fires. Does this for all controls on the child
> and grand children.
>
> Any ideas what to look at?
>
> Thanks,
> Jon