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

Error while compiling


zeeshanhashmi

Recommended Posts

Hi,

 

I have a report where I want to use java class to convert amount to workds. I converted the Java Class file to a JAR file and added that JAR file (ADD JAR) via iReport.

Now, when I tried to run that report I see the error window pops up and show this:

Please guide me how to fix this.

Thank you
Regards
=================================================

Error Message

Errors were encountered when compiling report expressions class file: 1. com.HashmiTech.NumberToWords cannot be resolved to a type value = com.HashmiTech.NumberToWords.convert( ((java.lang.Double)field_grand_total.getValue()) ); //$JR_EXPR_ID=9$ <------------------------> 2. com.HashmiTech.NumberToWords cannot be resolved to a type value = com.HashmiTech.NumberToWords.convert( ((java.lang.Double)field_grand_total.getValue()) ); //$JR_EXPR_ID=10$ <------------------------> 3. com.HashmiTech.NumberToWords cannot be resolved to a type value = com.HashmiTech.NumberToWords.convert( ((java.lang.Double)field_grand_total.getOldValue()) ); //$JR_EXPR_ID=9$ <------------------------> 4. com.HashmiTech.NumberToWords cannot be resolved to a type value = com.HashmiTech.NumberToWords.convert( ((java.lang.Double)field_grand_total.getOldValue()) ); //$JR_EXPR_ID=10$ <------------------------> 5. com.HashmiTech.NumberToWords cannot be resolved to a type value = com.HashmiTech.NumberToWords.convert( ((java.lang.Double)field_grand_total.getValue()) ); //$JR_EXPR_ID=9$ <------------------------> 6. com.HashmiTech.NumberToWords cannot be resolved to a type value = com.HashmiTech.NumberToWords.convert( ((java.lang.Double)field_grand_total.getValue()) ); //$JR_EXPR_ID=10$ <------------------------> 6 errors

=================================================


 

Link to comment
Share on other sites

  • Replies 6
  • Created
  • Last Reply

Top Posters In This Topic

Seems like you have a data type problem. What datatype does com.HashmiTech.NumberToWords return? What's the expression where it's uses? Are you using Scriptlets? Try using a variable in your field or parameter expression and calling calling your java class in your variable, but before you do, try setting a value in your variable to make sure your expressions works.

Link to comment
Share on other sites

  • 3 months 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...