TXMLDocumentSaveToXML (C++)

From RAD Studio Code Examples
Jump to: navigation, search

Description

The following example uses the SaveToXML function.

Code

void Test_SaveToXML() {
	_di_IXMLDocument document = interface_cast<Xmlintf::IXMLDocument>
		(new TXMLDocument(NULL));

	document->LoadFromFile(srcPath);

	// Save content to DOM string and display the string.
	String content; // The DOMString class is not defined in C++.
	document->SaveToXML(content);
	printf("%ls\n", content);
}

Uses