How to load a custom call from another project?

Possible duplicate:
Using custom controls from other projects in ASP

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

Now I am building A and adding a link to A in B. How can I load a user control in B and access the controls in this user control?

Do I want to avoid reconnecting Project Beach time I change one of the user controls?

+1
source share
1 answer

I use for this, working with IIS, ASP.NET 4.0:

  • myControl.ascx. , A A SharedControls.
  • IIS ( , script) B, 'ASharedControls', A SharedControls ( , B, A web.config hierachy, B)
  • B A
  • B <%@ Register TagPrefix="uc1" TagName="myControl" Src="~/ASharedControls/myControl.ascx" %> (VS , , IIS)
  • myControl codebehind B .

, codefile/codebehind, batch = "false" web.config, :

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

,

+1

All Articles