IF ISCLEAR(XMLDOMDocument) THEN CREATE(XMLDOMDocument); IF ISCLEAR(XMLDocOut) THEN CREATE(XMLDocOut); DocNameSpace := ''; SoapEnvelope := '<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" ' + 'xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope"/>'; XMLDomDocInst := XMLDOMDocument.createProcessingInstruction('xml','version="1.0" encoding="UTF-8"'); CurrNode := XMLDOMDocument.appendChild(XMLDomDocInst); XMLDOMDocument.loadXML := (SoapEnvelope); CurrNode := XMLDOMDocument.documentElement; AddElement(CurrNode,'testPing', 'xmlns="http://xxx"',DocNameSpace,NewChild); CurrNode := NewChild; AddElement(CurrNode,'apiKey','API_KEY_VALUE,DocNameSpace,NewChild); CurrNode := CurrNode.parentNode; XMLDOMDocument.save('C:\XMLBuffer\TEST.xml');
Comments
2. a complete sample which works:
...
Everybody on-line.
...
Looking good!