posted 15 years ago
Hello:
I have been trying to use the following method to write my Document (chartDoc) to a file:
Source source = new DOMSource(chartDoc);
File file = new File("c:/test/slide11.xml");
Result result = new StreamResult(file);
Transformer xformer = TransformerFactory.newInstance().newTransformer();
xformer.transform(source, result);
The file is created but it is empty. I know that the Document is fine as it is used successfully for other purposes. I have tried using OutputKeys to no avail. Any ideas?
Thanks
Eric