XmlDataDocument.CloneNode(Boolean) Method

Definition

Creates a duplicate of the current node.

public:
 override System::Xml::XmlNode ^ CloneNode(bool deep);
public override System.Xml.XmlNode CloneNode(bool deep);
override this.CloneNode : bool -> System.Xml.XmlNode
Public Overrides Function CloneNode (deep As Boolean) As XmlNode

Parameters

deep
Boolean

true to recursively clone the subtree under the specified node; false to clone only the node itself.

Returns

The cloned node.

Remarks

Cloning the XmlDataDocument also clones the DataSet schema.

If deep is set to false, the cloned DataSet has no data; that is, no rows.

If deep is set to true, the cloned DataSet is set with the schema and then populated with the data.

See CloneNode in the XmlNode class to see a table describing how this method behaves with each of the different node types.

Applies to