This week's book giveaways are in the Java EE and JavaScript forums.
We're giving away four copies each of The Java EE 7 Tutorial Volume 1 or Volume 2(winners choice) and jQuery UI in Action and have the authors on-line!
See this thread and this one for details.
The moose likes XML and Related Technologies and the fly likes editing data in  xml file Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Engineering » XML and Related Technologies
Bookmark "editing data in  xml file" Watch "editing data in  xml file" New topic
Author

editing data in xml file

siva sankar
Ranch Hand

Joined: Jul 13, 2006
Posts: 68
HI,

I have a xml file ex.xml.Now i want to add some more data to the existing xml file through a java program using DOM.Can it be possible?if yes,how can we do this?

Thanks in Advance,
Regards,
Siva
Paul Sturrock
Bartender

Joined: Apr 14, 2004
Posts: 10336

Yes. Have a look at the JavaDocs for org.w3c.dom; you can add nodes, remove them, change attributes and values etc.
[ April 04, 2007: Message edited by: Paul Sturrock ]

JavaRanch FAQ HowToAskQuestionsOnJavaRanch
 
Consider Paul's rocket mass heater.
 
subject: editing data in xml file