Groups | Blog | Home
all groups > asp.net building controls > september 2004 >

asp.net building controls : UserControl not capturing Button click event when loaded with PlaceHolder Control


gordingin NO[at]SPAM consiliumsoft.com
9/15/2004 1:55:10 PM
My UI is one table, 2 colums, one row. The cell on the left has a tree
and the cell on the right has a placeholder control. When the user
clicks on a tree item, I dynamically load the apporopiate user control
into the PlaceHolder control using this code...

objPlaceHolder.Controls.Clear();
objPlaceHolder.Controls.Add(LoadControl("nnn.ascx"));

where nnn.ascx is the appropiate control. On this user control I have
a button and hander defined but when I click on the button, the
handler NEVER gets called.

I am not sure why this happens....

Thanks
Ralph Krausse

www.consiliumsoft.com
Use the START button? Then you need CSFastRunII...
A new kind of application launcher integrated in the taskbar!
John Saunders
9/15/2004 5:15:31 PM
[quoted text, click to view]

When does the above code get called? You have to call it on every request.

John Saunders

AddThis Social Bookmark Button