System.Web.UI.WebControls.SiteMapNodeItem Class

The System.Web.UI.WebControls.SiteMapNodeItem class is used by the System.Web.UI.WebControls.SiteMapPath control to functionally represent a System.Web.SiteMapNode.

See Also: SiteMapNodeItem Members


public class SiteMapNodeItem : WebControl, System.Web.UI.IDataItemContainer


The System.Web.UI.WebControls.SiteMapPath control is a System.Web.UI.WebControls.CompositeControl, which means it renders a user interface composed of many other Web server controls. While the System.Web.UI.WebControls.SiteMapPath control works directly with the System.Web.SiteMap configured for your site and its System.Web.SiteMapNode objects, the System.Web.SiteMapNode objects are not Web server controls. The System.Web.UI.WebControls.SiteMapNodeItem class is a Web server control wrapper for the System.Web.SiteMapNode class, which enables the System.Web.UI.WebControls.SiteMapPath control to display System.Web.SiteMapNode data while maintaining the functional distinction between a generic navigation data item and a user interface item.

The System.Web.UI.WebControls.SiteMapPath control maintains the site map nodes in its System.Web.UI.Control.Controls collection internally. Because the System.Web.UI.WebControls.SiteMapPath can render its child controls with different styles, templates, and orders, it must be able to distinguish between functionally different types of nodes, regardless of display order. For this reason, each System.Web.UI.WebControls.SiteMapNodeItem is created with a specific type. (Possible types are listed in the System.Web.UI.WebControls.SiteMapNodeItemType enumeration.)

Use the System.Web.UI.WebControls.SiteMapNodeItem class directly in your code only if you plan to extend the System.Web.UI.WebControls.SiteMapPath control or write a control with similar functionality.


Namespace: System.Web.UI.WebControls
Assembly: System.Web (in System.Web.dll)
Assembly Versions:
Since: .NET 2.0