Solved

PlaceHolder and Web User Controls

Posted on 2007-11-20
1
651 Views
Last Modified: 2012-06-27
Can I add a Web User Control to an asp:PlaceHolder at runtime?

How?
0
Comment
Question by:knowlton
1 Comment
 
LVL 3

Accepted Solution

by:
john_steed earned 500 total points
ID: 20322345
Like this

if(!Page.IsPostBack)
{
    WebUserControl1 uc =
      (WebUserControl1) Page.LoadControl("WebUserControl1.ascx");
    PlaceHolder1.Controls.Add(uc);
}
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, Just open a new email message.  In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…
This tutorial demonstrates a quick way of adding group price to multiple Magento products.

746 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now