cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

How to read XML Values using JAVA

Former Member
0 Likes
338

Hi FRNDS,

I uploaded one XML File in imported Archieves, i have to read the value form XML uisng JAVA code,

using XSL able to read like xsl variable name='TimeZone' select =$linkDoc//...........*

But using java i have to read the value from XML,is it possible to read the value??

please give me some sample code.

regards,

Raja Sekhar

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Likes

thanks,

sunilchandra007
Active Contributor
0 Likes

Hi,

For reading XML through Java, Parsing (DOM, SAX) technique is used.

Just google How to read XML Values using JAVA, you will get a lots of links.

For reference, you can go through these links :-

1. www.java-tips.org/java-se-tips/javax.xml.parsers/how-to-read-xml-file-in-java.html

2. www.totheriver.com/learn/xml/xmltutorial.html

Regards,

Chandra

Former Member
0 Likes
But using java i have to read the value from XML,is it possible to read the value??

Check the below JAVA code from help:

http://help.sap.com/saphelp_nwpi71/helpdata/en/55/7ef3003fc411d6b1f700508b5d5211/content.htm

you can ignore the XSLT part and configure only the JAVA code...check if this suits your needs.

Regards,

Abhishek.