Bijal
|
Posted: May 06, 2010 17:20 by Bijal
|
|
I'm using ODFDOM to search and replace tags within an odt file. All works well, however now I need to load a multi-line string containing line feeds and retain them in the odt file. When I perform the Node replacement the linefeeds are gone. Is there a way to retain line feeds? String myString = " text1 \r\n text2 \r\n text3 \r\n"; Node textBit = textBits.item(bits); Sring text = textBit.getTextContent(); ... replacedText = text.replace("<<" + templateFieldName + ">>", myString); textBit.setTextContent(replacedText); |
Retain Line Feeds for Tag replacement
2 posts
» Share this
Replies: 1 - Last Post: June 24, 2010 07:12
by: narsing
by: narsing
showing 1 - 2 of 2
Replies: 1 - Last Post: June 24, 2010 07:12
by: narsing
by: narsing


