Create Line Break in XML NODE using Java DOM Parser

CairoCairo

New Member
I'm Creating Dynamic XML Document using Java DOM.Kindly find corresponding code below\[code\]Element cond = doc.createElement("condition");Text value = http://stackoverflow.com/questions/12558763/doc.createTextNode("simulation/sim-time-sec ge 0.25 \r\n\r\n dss");cond.appendChild(value);event.appendChild(cond);\[/code\]The above code results \[code\]<condition>simulation/sim-time-sec ge 0.25 dss</condition> \[/code\]But i want node like below\[code\]<condition> simulation/sim-time-sec ge 0.25 dss</condition> \[/code\]Kindly Suggest the solution in Java. Thanks in advance.
 
Back
Top