asp.net - Solution for: Element <element> is not a known element warning in vs2008 when using User controls -


I had a VS2008 project that was showing this warning, and I could not find a solution anywhere - maybe my Google- Fu is weak.

In any case, its clear solution is to ensure that the tag name is the name of the control class.

So for my example, the following warning was displayed:

  & lt;% @ register Src = "~ / path / to / control.ascx" tagname = "Tagname" tagprix = "tagprinfix"%>  

& lt; Tagprefix: tagName runat = "server" id = "controlID" />

but it is changing in:

  & lt;% @ register Src = "~ / path / to / control.ascx" tag name = "Control" tagfix = "tagprinfix"%>  

& lt; TagProufix: control runat = "server" id = "controlID" />

= "Text">

This sounds like your classic recycling and "Close and reopen the Visual Studio" problem.

It is possible that this may also be related to a similar problem on which I replied.


Comments