System.Web.UI.WebControls.SiteMapPath.NodeTemplate Property

Gets or sets a control template to use for all functional nodes of a site navigation path.

Syntax

[System.ComponentModel.Browsable(false)]
[System.Web.UI.PersistenceMode(System.Web.UI.PersistenceMode.InnerProperty)]
[System.Web.UI.TemplateContainer(typeof(System.Web.UI.WebControls.SiteMapNodeItem), System.ComponentModel.BindingDirection.OneWay)]
[System.ComponentModel.DefaultValue(null)]
public virtual System.Web.UI.ITemplate NodeTemplate { set; get; }

Value

Documentation for this section has not yet been entered.

Remarks

Set the SiteMapPath.NodeTemplate to an System.Web.UI.ITemplate object to use an System.Web.UI.WebControls.Image or some other control, such as a System.Web.UI.WebControls.Label, as a user interface element for all navigation path nodes.

If the SiteMapPath.NodeTemplate property is set, the template overrides both the navigation node text displayed and any SiteMapPath.NodeStyle applied to it. For the current and root nodes, if a SiteMapPath.CurrentNodeTemplate or SiteMapPath.RootNodeTemplate is set, these templates override the SiteMapPath.NodeTemplate.

You can declaratively set the SiteMapPath.NodeTemplate property to any Web server control, and the ASP.NET infrastructure performs the necessary steps to wrap the Web server control as an System.Web.UI.ITemplate object. However, Web server controls do not implement the System.Web.UI.ITemplate interface; therefore, when you work with the System.Web.UI.ITemplate properties programmatically, you must write an System.Web.UI.ITemplate wrapper for any template code. Then, the SiteMapPath.RootNodeTemplate property is set to an instance of the System.Web.UI.ITemplate wrapper.

Requirements

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