Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8954203
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T14:16:05+00:00 2026-06-15T14:16:05+00:00

Possible Duplicate: Using User Controls from Other Projects in ASP I have the following

  • 0

Possible Duplicate:
Using User Controls from Other Projects in ASP

I have the following case: A solution has two projects, A and B. One of them, A, has a UserControl.

Now I build A and add a reference to A in B. How is it possible to load the user control in B and access the controls in that user control?

I want to avoid to rebuild Project B every time i change one of the user controls ?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T14:16:06+00:00Added an answer on June 15, 2026 at 2:16 pm

    I use to proceed like this, working with IIS, ASP.NET 4.0 :

    1. Place the control myControl.ascx I want A to share in a subfolder of Application A named SharedControls
    2. in IIS, add a virtual directory (no app, but with execute script rights) to B, ‘ASharedControls’, pointing on A’s SharedControls (referencing this subdirectory, you will avoid B including A’s web.config in it’s hierachy, which would make B crash)
    3. In B, add a project reference to A
    4. In B, you can now declare and use your control in markup with
      <%@ Register TagPrefix="uc1" TagName="myControl" Src="~/ASharedControls/myControl.ascx" %> (VS will warn as path not found, but it should work in IIS)
    5. myControl should then be also available in codebehind for B’s pages and controls

    Depending on your pages and controls being codefile/codebehind, you might have to set batch=”false” in web.config compilation element, to avoid multi-compilation conflicts :

    <compilation defaultLanguage="c#" debug="true" batch="false" targetFramework="4.0">
    

    Hope this will help

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Possible Duplicate: How to retrieve user's current city name? using the following methods i
Possible Duplicate: Using ASP.NET Controls without databinding My previous question yielded few results so
Possible Duplicate: Using a bitwise & inside an if statement I have the following
Possible Duplicate: filter using Q object with dynamic from user? I am working on
Possible Duplicate: using seo user friendly in php I have 3 PHP files: index1.php,
Possible Duplicate: Redirecting to a new page when a user is using Internet Explorer
Possible Duplicate: Force Download an Image Using Javascript Basically I want to have the
Possible Duplicate: How to reload a page using Javascript? I have the Facebook login
Possible Duplicate: Going from database to sessions A user enters information, which I stored
Possible Duplicate: Python read a single character from the user I am looking to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.