A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Win a copy of
Refactoring for Software Design Smells: Managing Technical Debt
this week in the
OO, Patterns, UML and Refactoring
XML and Related Technologies
Writing XML File via Java Program
Joined: Mar 07, 2006
Jan 05, 2010 09:32:14
Hi Friends, It's regarding writing xml file via
transformerFactory = TransformerFactory.newInstance();
Transformer transformer = transformerFactory.newTransformer();
source = new
result = new
In the above code it's displaying data's.
Now i want to write this data's to xml file. (How to process transformer value)
Please help me on this. Thanks.
Joined: Oct 14, 2005
Jan 05, 2010 09:36:09
So you want to write it to a file instead of System.out? Then just change System.out to something which outputs to that file instead of to the console.
Ravi Kiran Va
Joined: Apr 18, 2009
Jan 13, 2010 11:59:35
Use Xstream API .
Try it .
Save India From Corruption - Anna Hazare.
Have you checked out
subject: Writing XML File via Java Program
XSLT transformer formatting
redirect XML/DOM output to file??
xml output formatting
problem with writing the file
XML on the fly using servlets
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2015