Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Search and Modify in XML String  RSS feed

 
Ullas padavan
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I have a XML string and I need to search for a specified tag in it and then modify the text value. What is best way of doing it programatically?

Thanks
 
Haroon Chaudhary
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you are familiar with xpath expression and your XML string is of reasonable size then I think you can use javax.xml.xpath.XPathExpression to search the element and then modify the vlaue.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!