access denied (java.io.FilePermission "report.jrxml" read)
I am having trouple opening a report developed in iReport. I have done some searching on this and havent found anything that has helped. I get the following error message when I try to run the report.
"java.security.AccessControlException: access denied (java.io.FilePermission C:\Users\banny7\sched\Report.jrxml read)
at java.security.AccessControlContext.checkPermission (AccessControlContext.java:374)
at java.security.AccessController.checkPermission(Acc essController.java:546)"
The wired thing is that when the application is on the dev server it works but when I move it over to the production server. I get the error message. Both servers are using Tomcat 7.0. The second line of code below is what trigers java to read the .jrxml file. The file is not a read-only file and is in a directory that is create by the application at start up.
Code :
JasperDesign jasperDesign = JRXmlLoader.load("C:\Users\banny7\sched\Report.jrxml");
JasperReport jasperReport = JasperCompileManager.compileReport(jasperDesign);
Any help would be appreciated
Re: access denied (java.io.FilePermission "report.jrxml" read)
Does the application trying to read the report have permission to read files within that directory? Is the directory structure and user permission set up the same on the test and production server?
Re: access denied (java.io.FilePermission "report.jrxml" read)
Yes they are set up the same. But I discovered later it has to do with the permissions on my computer and one other users computer. Other users can view the report. We think it has to do with the iText jar that goes with iReports.