We have been asked by a client if we can set the Advanced parameters in word, such as title, author etc.
In jasper this is done by using SimpleDocxExporterConfiguration and add it to AWDocxExporter with setConfiguration().
However it seems that aspose haven’t implemented the newer use of setExporterInput()/setExporterOutput() according to what I could find in the forum. I tried to set the configuration and still use parameters such as AWExporterParameter.JASPER_PRINT, AWExporterParameter.OUTPUT_FILE_NAME but that caused the following error:
Caused by: net.sf.jasperreports.engine.JRRuntimeException: Can't mix deprecated JRParameter API calls with new exporter configuration API calls.
at net.sf.jasperreports.engine.JRAbstractExporter.checkApi(JRAbstractExporter.java:309)
at net.sf.jasperreports.engine.JRAbstractExporter.setParameter(JRAbstractExporter.java:345)
at com.aspose.words.jasperreports.internal.awjr3192.setParameter(Unknown Source)
at idainfront.forensic.lims.report.jasper.JasperReportProcess.generateReport(JasperReportProcess.java:192)
If I tried to use the exporter.setExporterInput(()/exporter.setExporterOutput() I can’t generate my report because there is no output chosen.
Is there a way around this or is it at the moment impossible to set this metadata information?
Seems like Aspose also swollows it up if I try to set them in the report directly with net.sf.jasperreports.export.docx.metadata..
File with my configuration for example.
AWDocxExporter exporter.docx (13.2 KB)