RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TXMLNodeList.ReplaceNode Method

Replaces a node in the list with another node.

Pascal
function ReplaceNode(const OldNode: IXMLNode; const NewNode: IXMLNode): IXMLNode;
C++
__fastcall IXMLNode ReplaceNode(const IXMLNode OldNode, const IXMLNode NewNode);

Call ReplaceNode to replace the node specified by OldNode with the node specified by NewNode. 

OldNode is the node to replace. If OldNode does not appear in the list, then ReplaceNode adds the new node to the end of the list. 

NewNode is the node to add to the list in place of OldNode. 

ReplaceNode returns OldNode (even if OldNode did not appear in the list). 

 

Copyright(C) 2008 CodeGear(TM). All Rights Reserved.
What do you think about this topic? Send feedback!