ASP.NET controls from different assemblies

I have some controls in my GeneralControls assembly (classic DLL) that consist of a .ascx file (and code for them).

I reference this DLL and use controls like:

<%@ Register Tagprefix="g" Assembly="GeneralControls" Namespace="GeneralControls.UI" %>


<g:FooterControl ID="Footer" runat="server" />

but FooterControl contains some other controls (labels, etc.), and those used with codebehind throw NullArgumentException. What is the correct way to share ascx controls? Thanks in advance.

+3
source share
1 answer

(.ascx) -, . .

, , , , CreateChildControls ..

http://support.microsoft.com/kb/893667 (. " ?" )

+3

Source: https://habr.com/ru/post/1752484/


All Articles