all groups > asp.net webcontrols > december 2006 >
You're in the

asp.net webcontrols

group:

Using Web.config's <system.web><pages><controls><add /></controls></pages></system.web> To Register UserControls


Using Web.config's <system.web><pages><controls><add /></controls></pages></system.web> To Register UserControls Nathan Sokalski
12/19/2006 9:02:20 PM
asp.net webcontrols:
My Web.config file contains the following section to register some of my
UserControls:

<pages>
<controls>
<add tagPrefix="NATE" tagName="Banner" src="~/Banner.ascx"/>
<add tagPrefix="NATE" tagName="Navigation" src="~/Navigation.ascx"/>
</controls>
</pages>

However, I still receive the following error:

Element 'Banner' is not a known element. This can occur if there is a
compilation error in the Web site.
Element 'Navigation' is not a known element. This can occur if there is a
compilation error in the Web site.

I have tried compiling, and this is the only error I receive. Is there
something I am forgetting to do? Is there something wrong with my Web.config
file? Thanks.
--
Nathan Sokalski
njsokalski@hotmail.com
http://www.nathansokalski.com/

Re: Using Web.config's <system.web><pages><controls><add /></controls></pages></system.web> To Register UserControls Brock Allen
12/20/2006 12:00:00 AM
Put the ASCX files into a subdirectory and then try it.

-Brock
http://staff.develop.com/ballen


[quoted text, click to view]

AddThis Social Bookmark Button