0
votes

Please I need someone to help me with this issue:

When I select an item from an .ascx usercontrol 'DropDownList Box' added to a master page with PlaceHolder1.Controls.Add(LoadControl("//UserControls/mycontrol.ascx"));

The .ascx user control disappears after the item has been selected

1
How and what event do you add the control ? show codeMichael B.

1 Answers

0
votes

You don't show your code, so it's hard to provide an exact answer. but probably you add your user control dynamically only one time and it disappears after each postback. You need to load Usercontrol after each postback so you need to load Usercontrol in something like Page_load method if you don't.