Previous Next

APPEND-CHILD( ) method
Appends a node as the last child node of this XML document or element node. Connects a node into the document structure after the node has been created with the CREATE-NODE( ) or CREATE-NODE-NAMESPACE( ) method, cloned with the CLONE-NODE( ) method, or disconnected with the REMOVE-NODE( ) method. This has no effect on the node reference.
If the node is already in the tree, it is disconnected from its present location and then connected at the specified location.
Return type:
Applies to:
 
Syntax 
APPEND-CHILD ( x-node-handle )
x-node-handle
The handle that represents the node to append to this XML document or element node. x-node-handle must refer to a node in this document. You cannot use APPEND-CHILD( ) to move a node from one document to another.
The following code fragment demonstrates creating a node in a tree with the name and value of a field:
 
. . .
hDoc:CREATE-NODE(hNoderef, bufField:NAME, "ELEMENT").
hNoderefParent:APPEND-CHILD(hNoderef).
hDoc:CREATE-NODE(hText, "", "TEXT").
hText:NODE-VALUE = STRING(bufField:BUFFER-VALUE).
hNoderef:APPEND-CHILD(hText).
. . .

Previous Next
© 2013 Progress Software Corporation and/or its subsidiaries or affiliates.