Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to use external JAR file in JasperSoft Studio

I have project in iReport, I want to build this in jasper studio,in that I use some external jar file to convert date, but in jasper studio I cant use them, I add those jar file in right click on project folder > properties > java build path > libraries > add External JARs.., I get error when I want to see report preview :

net.sf.jasperreports.engine.JRException: Errors were encountered when compiling report expressions class file:
1. com.ghasemkiani.util.icu.PersianDateFormat cannot be resolved to a type
                value = new com.ghasemkiani.util.icu.PersianDateFormat("yyyy/MM/dd").format(((java.sql.Timestamp)field_ORDERDATE.getValue())); //$JR_EXPR_ID=9$
                            <---------------------------------------->
2. com.ghasemkiani.util.icu.PersianDateFormat cannot be resolved to a type
                value = new com.ghasemkiani.util.icu.PersianDateFormat("yyyy/MM/dd").format(((java.sql.Timestamp)field_ORDERDATE.getOldValue())); //$JR_EXPR_ID=9$
                            <----------------------------------------> 

so,my question is : how can I add external jar file and use it?

like image 673
Samira Khorshidi Avatar asked Dec 17 '25 01:12

Samira Khorshidi


1 Answers

After you have added jar file to build path you have to restart your Jasper Studio.

like image 75
EA0906 Avatar answered Dec 19 '25 20:12

EA0906



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!