2005 IR Help Posted August 26, 2006 Share Posted August 26, 2006 By: Vishy - vishyn error: cannot resolve "Scriptlet" class 2004-05-06 14:02 Hi, All these days, I was successfully using scriptlet classes in my reports and today I am getting an error that jasper is unable to resolve the scriptlet class name. All this time I was giving fully qualified class name and it was working. Please tell me where I am doing wrong? Can there be a possibility of something being wrong in my build.jasper file(ant file) MasterReport.xml where I use scriptlet.. <jasperReport name="CategoriesReport" columnCount="1" ....... ............. scriptletClass="com.sample.reports.beans.SubCategoriesListingScriptlet"> .......... <variable name="SubCategoriesCollection" class="java.util.Collection" resetType="Report" calculation="System"> <initialValueExpression><![CDATA[new java.util.ArrayList()]]></initialValueExpression> ........... <reportElement mode="Opaque".......... <printWhenExpression> <![CDATA[((com.samplereports.beans.SubCategoriesListingScriptlet)$P{REPORT_SCRIPTLET}).getSubCategories($P{SelectedSubCategory},$P{OrganizationId}, $F{Id})]]> </printWhenExpression> </reportElement> "CategoriesReport.java":[jrc] C:samplejavasamplewebappWEB-INFtempCategoriesReport.java:139: cannot resolve symbol: class SubCategoriesListingScriptlet in package beans at line 139 [jrc]value = (java.lang.Boolean)(((com.quickhire.bacon.reports.beans.SubCategoriesListingScriptlet)((dori.jasper.engine.JRAbstractScriptlet)parameter_REPORT_SCRIPTLET.getValue())).getSubCategories(((java.lang.Object)parameter_SelectedSubCategory.getValue()),((java.lang.Integer)parameter_OrganizationId.getValue()), ((java.lang.String)field_Id.getValue()))); [jrc] dori.jasper.engine.JRException: Errors were encountered when compiling report expressions class file: ANT FILE ANT FLE JASPER BUILD FILE <property name="classes1.dir" value="C:/sample/java/jasperReports/classes" /> <property name="classes2.dir" value="C:/sample/java/quickhire/webapp/WEB-INF/classes" /> <property name="lib.dir" value="C:/smaple/java/jasperReports/lib" /> <path id="classpath"> <pathelement location="./"/> <pathelement location="${classes1.dir}" /> <pathelement location="${classes2.dir}" /> <fileset dir="${lib.dir}"> <include name="**/*.jar"/> </fileset> </path> <taskdef name="jrc" classname="dori.jasper.ant.JRAntCompileTask"> <classpath refid="classpath"/> </taskdef> Many Thanks Vishy Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now