On Thu, 4 Sep 2014, Keith Denny wrote:
*Results:*
One call to r.getText(0) returns only '<<CLIENT_' ;therefore, there's no
match with the comparison check of the entity tag of <<CLIENT_NAME>>.  The
following call to r.getText(0) returns only 'NAME>>'.  Again, obviously, no
match.

This is normal. That's just how the word file format works. A given run contains text that is all styled the same. A paragraph is made up of possibly multiple runs, each run having text of the same style, each subsequent run may or may not have a different style

All depends on the history of the file, and what mood Word was in when creating it

2.  How do I ensure that I get the actual line, as it exists in the MS Word
document, in POI so I can inspect and replace key text?

Fetch the text at the paragraph level, then work out which run(s) to change within that taking account that a given bit of text could well be across multiple runs

Nick

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to