System.Web.SiteMapNode.Clone Method

Creates a new copy that is a copy of the current node, optionally cloning all parent and ancestor nodes of the current node.

Syntax

public virtual SiteMapNode Clone (bool cloneParentNodes)

Parameters

cloneParentNodes
true to clone all parent and ancestor nodes of the current node; otherwise, false.

Returns

A new node that is a copy of the current node.

Remarks

If the cloneParentNodes parameter is true, the SiteMapNode.Clone(bool) method recursively clones all direct ancestor nodes and associates them with the current cloned node. Child nodes are not cloned.

The SiteMapNode.Roles and SiteMapNode.Attributes collections are applied to new collections.

Requirements

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