+ Start a Discussion
Paras JainParas Jain 

how to read xml and fetch id(123456) and store this in my account object record

<abc><frokeId>123456</frokeId></abc>

 
Srinivas SSrinivas S
String myXML = '<abc><frokeId>123456</frokeId></abc>';
Dom.Document domDoc = new Dom.Document();
domDoc.load(myXML);
Dom.XMLNode rootNode = domDoc.getRootElement();
for(Dom.XMLNode child1 : rootNode.getChildElements()) {
	system.debug(child1.getText());
}

Please follow as specified. I have test by executing the above code in developer console > anonymous block, it is working.

------------
Thanks,
Srinivas
- Please mark as solution if your problem is resolved.