When docx contains a w:instrText like this :
--------------------------------------------------------------
<w:instrText xml:space="preserve"> MERGEFIELD "</w:instrText>
--------------------------------------------------------------
the preprocessing crashes :
--------------------------------------------------------------
Exception in thread "main" java.lang.StringIndexOutOfBoundsException: String
index out of range: -1
at java.lang.String.substring(Unknown Source)
at fr.opensagres.xdocreport.document.docx.preprocessor.sax.MergefieldBufferedRegion.getFieldName(MergefieldBufferedRegion.java:155)
--------------------------------------------------------------
See attached docx.
Original issue reported on code.google.com by angelo.z...@gmail.com on 8 Aug 2014 at 10:02
Original issue reported on code.google.com by
angelo.z...@gmail.com
on 8 Aug 2014 at 10:02Attachments: