Jump to content
We've recently updated our Privacy Statement, available here ×

I can't create any more reports with the jasper API


as_9

Recommended Posts

In the compilation i always get the warnings:

WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by net.sf.jasperreports.engine.util.ClassUtils (file:/C:/Development/Java/Eclipse%20Workspace/rpgen/lib/jasperreports-5.6.0.jar) to constructor com.sun.org.apache.xerces.internal.util.XMLGrammarPoolImpl()
WARNING: Please consider reporting this to the maintainers of net.sf.jasperreports.engine.util.ClassUtils
WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
WARNING: All illegal access operations will be denied in a future release
Mai 02, 2019 3:40:11 NACHM. net.sf.jasperreports.engine.design.JRJdk13Compiler compileClasses
INFO: Note: C:DevelopmentJavaEclipse Workspacerpgenblank_1556804410135_187077.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.

---------------------------------

The code should be correct:
The .jar looks like:
 

jasperMasterReport =JasperCompileManager.compileReport((String) (String.valueOf(reportTemplatePath) + sourceFile));jasperPrint = JasperFillManager.fillReport((JasperReport) jasperMasterReport,parameters, con);JasperExportManager.exportReportToPdfFile(jasperPrint, destinationFile);[/code]

the pdf is created but it is empty. For con i am using also a good connection string, that i tested multiple times.
If i use this connection string directly in jaspersoft studio, it works. But when i want to do it with the api, I always get these warnings and my pdf has no database input.

Last year I created many reports with this method.

Do you know what the problem is?

My jar has no depracated code. This "blank_1556804410135_187077.java" i guess it is created automatically with the compilation. 
I even cant create very simple reports with a single query.

Do I receive no data because the compilation uses depracted code? Or do I use a wrong java version? (java version "12.0.1" 2019-04-16)
 

Link to comment
Share on other sites

  • Replies 3
  • Created
  • Last Reply

Top Posters In This Topic

  • 2 months later...
  • 3 years later...

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 account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...