This documentation is archived and is not being maintained.

tagMapping Element for pages (ASP.NET Settings Schema)

Defines a collection of tag types that are remapped to other tag types at compile time.

This element is new in the .NET Framework version 2.0.

   <add /> 
   <remove /> 

The following sections describe attributes, child elements, and parent elements.



Child Elements

Element Description


Optional element.

Adds a tag mapping to the collection of tag mappings that are used during pre-compilation.


Optional element.

Removes all references to inherited tag mappings, allowing only the tag mappings that are added by the current add element.


Optional element.

Removes a reference to an inherited tag mapping from the collection of tag mappings.

Parent Elements

Element Description


Specifies the required root element in every configuration file that is used by the common language runtime and the .NET Framework applications.


Specifies the root element for the ASP.NET configuration settings in a configuration file and contains configuration elements that configure ASP.NET Web applications and control how the applications behave.


Defines page-specific configuration settings globally, such as ASP.NET directives, for pages and controls that are within the scope of the configuration file.

The tagMapping element defines a collection of tag types that are remapped to other tag types at compile time. This remapping causes the mapped type to be used in place of the original tag type for all pages and controls in the ASP.NET application within the scope of the configuration file.


Unlike other attributes and collections in the pages section, tag remapping has no matching ASP.NET page directive.

The following default tagMapping element is not explicitly configured in the Machine.config file or in the root Web.config file. However, it is the default configuration that is returned by the application.

      <clear />

The following code example shows how to specify values for several properties of the TagMapInfo class.

                MSPS.Web.dll, Version=''" 

Configuration section handler


Configuration member



Configurable locations


Root-level Web.config

Application-level Web.config

Virtual or physical directory–level Web.config


Microsoft Internet Information Services (IIS) version 5.0, 5.1, or 6.0

The .NET Framework version 2.0

Microsoft Visual Studio 2003 or Visual Studio 2005