TXMLDocumentAddChild (C++)
Description
The following example uses the CreateElement function.
Code
void Test_CreateElement() {
_di_IXMLDocument document;
_di_IXMLNode node;
document = interface_cast<Xmlintf::IXMLDocument>(new TXMLDocument(NULL));
document->Active = true;
node = document->CreateElement("TestElement", "");
document->DocumentElement = node;
// Display document content.
printf("%ls\n", document->XML->Text);
}
Uses
- Xml.XMLDoc.TXMLDocument.Active ( fr | de | ja )
- Xml.XMLDoc.TXMLDocument.CreateElement ( fr | de | ja )
- Xml.XMLDoc.TXMLDocument.XML ( fr | de | ja )