a.schaeferhoff Posted October 1, 2019 Share Posted October 1, 2019 I've added an excelmacro using net.sf.jasperreports.export.xlsx.macro.template to a report.Running this report in Jaspersoft Studio works fine. The report is generated, can be exported as xlsx, the xslx-file can be opened in excel and the macro can be executed.Running nearly (path to the macro-file is different) the same report in Jaserreport-Server is not working. The report is generated, can be exported as xlsx, but the xslx-file can not be opened in excel (invalid fileformat or fileextension).The macro has been "installed" on the Jasperreport-Server as "described" here.I'm using Jasperreport 6.3.0. Link to comment Share on other sites More sharing options...
swood_1 Posted October 1, 2019 Share Posted October 1, 2019 What does the reference to the macro file look like in the JRXML?What path have you put the macro file in?Or have you put it in the repository? Link to comment Share on other sites More sharing options...
a.schaeferhoff Posted October 2, 2019 Author Share Posted October 2, 2019 The reference to the macro file is set with net.sf.jasperreports.export.xlsx.macro.template and an absoulte path. Because I didn't know how to put the macrofile into the repository (what I prefer) i've choosen this way.But you gave the hint to check to access rights on the macro file.We will do this now. Link to comment Share on other sites More sharing options...
a.schaeferhoff Posted October 2, 2019 Author Share Posted October 2, 2019 We checked the rights on the macro-file. From our point of view everything looks ok.We made a test where we set an invalid filename for the excel macro file. In this case we got the following error message from the jasperreport server:net.sf.jasperreports.engine.JRException: Input stream not found at: /<deleted>/jasperserver/WEB-INF/macros/template_macros.xlsm.Running the report with the valid path and filename we got no error from the jasperreport server. But from excel when we try to open the file (format or extension invalid). Link to comment Share on other sites More sharing options...
a.schaeferhoff Posted October 4, 2019 Author Share Posted October 4, 2019 A possible reason (including work around) has been posted here. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now