After generating an XML file dynamically from a Java program I want the generated file to be displayed on the client's browser. How can I do that?
M.Kumar Sankar IBM's XML parser for Java provides a TXDocument class in which there is a method printWithFormat(writer). Give the servletResponseWriter to this argument so that the document will be displayed on to the client's browser, provided the browser supports the XML file format. When generating the XML file dynamically be careful to ensure that there are no null values, otherwise an exception will be thrown by printWithFormat.