Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Overview

Appends a new child in the specified xpath and executes the specified callback on created new node before inserting to DOM and returns the appended new node.

Xml myXml.AppendChild(xpath: string)

Appends a new child in the specified xpath and executes the specified callback on created new node before inserting to DOM and returns the appended new node.

Xml myXml.AppendChild(xpath: string, callback: (node: Xml) => any)

Arguments

string xpath

XPath of node to be append

(node: Xml) => any callback

Callback function to be execute.

Remarks

This method creates node and childs nodes according to the xml schema definition. If xml schema definition is not found in xml schema error is thrown.

...

Code Block
languagejs
$Xml.AppendChild('Customers/Customer', function(newNode) \{
  newNode.SetValue('Id','1');
\});