This documentation is archived and is not being maintained.

SiteMapNodeItem Class

The SiteMapNodeItem class is used by the SiteMapPath control to functionally represent a SiteMapNode.

Namespace:  System.Web.UI.WebControls
Assembly:  System.Web (in System.Web.dll)

[AspNetHostingPermissionAttribute(SecurityAction::LinkDemand, Level = AspNetHostingPermissionLevel::Minimal)]
[AspNetHostingPermissionAttribute(SecurityAction::InheritanceDemand, Level = AspNetHostingPermissionLevel::Minimal)]
public ref class SiteMapNodeItem : public WebControl, 
	IDataItemContainer, INamingContainer
<asp:SiteMapNodeItem />

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

The SiteMapPath control maintains the site map nodes in its Controls collection internally. Because the 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 SiteMapNodeItem is created with a specific type. (Possible types are listed in the SiteMapNodeItemType enumeration.)

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

The following code example demonstrates how to create and manipulate SiteMapNodeItem objects within the InitializeItem method of a class that derives from SiteMapPath. This code example is part of a larger example provided for the SiteMapPath class.

No code example is currently available or this language may not be supported.

System::Object
  System.Web.UI::Control
    System.Web.UI.WebControls::WebControl
      System.Web.UI.WebControls::SiteMapNodeItem

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Windows 7, Windows Vista, Windows XP SP2, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP Starter Edition, Windows Server 2008 R2, Windows Server 2008, Windows Server 2003, Windows Server 2000 SP4, Windows Millennium Edition, Windows 98

The .NET Framework and .NET Compact Framework do not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

.NET Framework

Supported in: 3.5, 3.0, 2.0
Show: