The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

How to: Include ASP.NET User Controls in Web Pages

Adding an ASP.NET user control to a Web page is similar to adding other server controls to the page. However, you must be sure to follow the procedure below so that all of the necessary elements are added to the page.

For information about how to create a custom user control, see How to: Create ASP.NET User Controls.

To add an ASP.NET user control to a Web page

  1. In Visual Web Developer, open the Web page to which you want to add the ASP.NET user control.

  2. Switch to Design view.

  3. Select your custom user control file in Solution Explorer, and drag it onto the page.

    The ASP.NET user control is added to the page. In addition, the designer creates the @ Register directive, which is required for the page to recognize the user control. You can now work with the control's public properties and methods.

Was this page helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

© 2015 Microsoft