First, it didn´t work, had to fix the line 268/269 from MailMerger.java
from:
- Code: Select all
tmp = tmp.trim();
String key = tmp.substring(0, tmp.indexOf(" ")) ;
to:
- Code: Select all
String key = tmp.trim();
Why the substring from 0 to " " ? The line before it does the trick, with the trim()..
Second, now it works almost perfectly !! But when i open the generated docx it still comes with the datasource reference, like "the following SQL command will be executed when this document blablabla", even tough if i say no the document opens OK with all the fields replaced correctly...
Any idea on how to remove this datasource reference so the result will look like a regular word document??
Thanks in advance!
![Mr. Green :mrgreen:](https://www.docx4java.org/forums/images/smilies/icon_mrgreen.gif)