XmlNode.RemoveChild Method (XmlNode)


Removes specified child node.

Namespace:   System.Xml
Assembly:  System.Xml (in System.Xml.dll)

abstract RemoveChild : 
        oldChild:XmlNode -> XmlNode
override RemoveChild : 
        oldChild:XmlNode -> XmlNode


Type: System.Xml.XmlNode

The node being removed.

Return Value

Type: System.Xml.XmlNode

The node removed.

Exception Condition

The oldChild is not a child of this node. Or this node is read-only.

Notes to Inheritors:

When overriding RemoveChild in a derived class, in order for events to be raised correctly, you must call the RemoveChild method of the base class.

The following example removes a node from the XML document.

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

Universal Windows Platform
Available since 10
.NET Framework
Available since 1.1
Return to top