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

Report with expression with functions from my own class does not works


karel.haruda_1
Go to solution Solved by karel.haruda_1,

Recommended Posts

Hi,

I have very simple use case of jasper report in JAVA 

 

                 InputStream reportDefinition = getReportDefinition(); //JRXML file                 Map<String, Object> params = getReportParameters();                 JasperPrint jasperPrint = null;                 JRDataSource source = createJRDataSource();                 try {                     JasperDesign design = JRXmlLoader.load(reportDefinition);                     JasperReport jasperReport = JasperCompileManager.compileReport(design);                     jasperPrint = JasperFillManager.fillReport(jasperReport, params, source); <-- here is exception                  } catch (Exception e) {                     jasperPrint = null;                 }                    [/code]

I got error 

net.sf.jasperreports.engine.fill.JRExpressionEvalException: Error evaluating expression for source text: eu.abra.utils.DateUtils.dateToSimpleLocalizedString(eu.abra.utils.DateUtils.doubleToDate($F{DATUM}))

Class DateUtils is public and is accessable in this java application.. Everything wokrs well before I updated jasper reports to version 6.4.0

Is there  any simple solution how to force jasper report to know my class DateUtils ? 

 

Thank you very much

Karel.

 

 

Link to comment
Share on other sites

  • Replies 1
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

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...