Preview in Studio and Writing out of Eclipse - App doesn't work

0

Hello Jaspersoft Community,

i have a problem regarding my datasource in Jaspersoft Studio.

When i want to look at the preview of my report i get the following error in Jaspersoft Studio

net.sf.jasperreports.engine.JRException:
net.sf.jasperreports.engine.fill.JRExpressionEvalException: Error
evaluating expression :
    Source text : $F{globalAngaben}.getPruefberichtnr()
    at com.jaspersoft.studio.editor.preview.view.control.ReportControler.fillReport(ReportControler.java:466)
    at com.jaspersoft.studio.editor.preview.view.control.ReportControler.access$18(ReportControler.java:441)
    at com.jaspersoft.studio.editor.preview.view.control.ReportControler$4.run(ReportControler.java:333)
    at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)
Caused by: net.sf.jasperreports.engine.fill.JRExpressionEvalException: Error evaluating expression :
    Source text : $F{globalAngaben}.getPruefberichtnr()
    at net.sf.jasperreports.engine.fill.JREvaluator.evaluate(JREvaluator.java:263)
    at net.sf.jasperreports.engine.fill.JRCalculator.evaluate(JRCalculator.java:611)
    at net.sf.jasperreports.engine.fill.JRCalculator.evaluate(JRCalculator.java:579)
    at net.sf.jasperreports.engine.fill.JRFillElement.evaluateExpression(JRFillElement.java:1016)
    at net.sf.jasperreports.engine.fill.JRFillTextField.evaluateText(JRFillTextField.java:504)
    at net.sf.jasperreports.engine.fill.JRFillTextField.evaluate(JRFillTextField.java:488)
    at net.sf.jasperreports.engine.fill.JRFillElementContainer.evaluate(JRFillElementContainer.java:259)
    at net.sf.jasperreports.engine.fill.JRFillBand.evaluate(JRFillBand.java:456)
    at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillTitle(JRVerticalFiller.java:354)
    at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReportStart(JRVerticalFiller.java:290)
    at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReport(JRVerticalFiller.java:152)
    at net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:963)
    at net.sf.jasperreports.engine.fill.BaseFillHandle$ReportFiller.run(BaseFillHandle.java:120)
    at java.lang.Thread.run(Unknown Source)
Caused
by: java.lang.ClassCastException:
com.systech.ge.client.dao.GlobalAngaben cannot be cast to
com.systech.ge.client.dao.GlobalAngaben
    at Gerentform_A4_1425317364309_973729.evaluate(Gerentform_A4_1425317364309_973729:215)
    at net.sf.jasperreports.engine.fill.JREvaluator.evaluate(JREvaluator.java:250)
    ... 13 more

When i compile my report i get no error.

In Eclipse, when i want to use the compiled report in my Java App, i get this

WARNUNG: Found two components for namespace
http://jasperreports.sourceforge.net/jasperreports/components
 
net.sf.jasperreports.engine.fill.JRExpressionEvalException: Error
evaluating expression :
 
    Source text : $F{globalAngaben}.getPruefberichtnr()
 
    at
net.sf.jasperreports.engine.fill.JREvaluator.evaluate(JREvaluator.java:263)
 
    at
net.sf.jasperreports.engine.fill.JRCalculator.evaluate(JRCalculator.java:611)
 
    at
net.sf.jasperreports.engine.fill.JRCalculator.evaluate(JRCalculator.java:579)
 
    at
net.sf.jasperreports.engine.fill.JRFillElement.evaluateExpression(JRFillElement.java:1016)
 
    at
net.sf.jasperreports.engine.fill.JRFillTextField.evaluateText(JRFillTextField.java:504)
 
    at
net.sf.jasperreports.engine.fill.JRFillTextField.evaluate(JRFillTextField.java:488)
 
    at
net.sf.jasperreports.engine.fill.JRFillElementContainer.evaluate(JRFillElementContainer.java:259)
 
    at
net.sf.jasperreports.engine.fill.JRFillBand.evaluate(JRFillBand.java:456)
 
    at
net.sf.jasperreports.engine.fill.JRVerticalFiller.fillTitle(JRVerticalFiller.java:354)
 
    at
net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReportStart(JRVerticalFiller.java:290)
 
    at
net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReport(JRVerticalFiller.java:152)
 
    at
net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:963)
 
    at
net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:892)
 
    at net.sf.jasperreports.engine.fill.JRFiller.fill(JRFiller.java:114)
 
    at
net.sf.jasperreports.engine.JasperFillManager.fill(JasperFillManager.java:668)
 
    at
net.sf.jasperreports.engine.JasperFillManager.fill(JasperFillManager.java:649)
 
    at
net.sf.jasperreports.engine.JasperFillManager.fillReport(JasperFillManager.java:971)
 
    at
com.systech.GerentForm.handlers.PDFHandler.createPDF(PDFHandler.java:97)
 
    at
com.systech.GerentForm.handlers.PDFHandler.execute(PDFHandler.java:55)
 
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
 
    at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
 
    at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
 
    at java.lang.reflect.Method.invoke(Method.java:606)
 
    at
org.eclipse.e4.core.internal.di.MethodRequestor.execute(MethodRequestor.java:56)
 
    at
org.eclipse.e4.core.internal.di.InjectorImpl.invokeUsingClass(InjectorImpl.java:243)
 
    at
org.eclipse.e4.core.internal.di.InjectorImpl.invoke(InjectorImpl.java:224)
 
    at
org.eclipse.e4.core.contexts.ContextInjectionFactory.invoke(ContextInjectionFactory.java:132)
 
    at
org.eclipse.e4.core.commands.internal.HandlerServiceHandler.execute(HandlerServiceHandler.java:167)
 
    at
org.eclipse.core.commands.Command.executeWithChecks(Command.java:499)
 
    at
org.eclipse.core.commands.ParameterizedCommand.executeWithChecks(ParameterizedCommand.java:508)
 
    at
org.eclipse.e4.core.commands.internal.HandlerServiceImpl.executeHandler(HandlerServiceImpl.java:213)
 
    at
org.eclipse.e4.ui.workbench.renderers.swt.HandledContributionItem.executeItem(HandledContributionItem.java:850)
 
    at
org.eclipse.e4.ui.workbench.renderers.swt.HandledContributionItem.handleWidgetSelection(HandledContributionItem.java:743)
 
    at
org.eclipse.e4.ui.workbench.renderers.swt.HandledContributionItem.access$7(HandledContributionItem.java:727)
 
    at
org.eclipse.e4.ui.workbench.renderers.swt.HandledContributionItem$4.handleEvent(HandledContributionItem.java:662)
 
    at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
 
    at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1392)
 
    at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3742)
 
    at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3363)
 
    at
org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$9.run(PartRenderingEngine.java:1113)
 
    at
org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
 
    at
org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:997)
 
    at
org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:140)
 
    at
org.eclipse.e4.ui.internal.workbench.swt.E4Application.start(E4Application.java:162)
 
    at
org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
 
    at
org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
 
    at
org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
 
    at
org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:354)
 
    at
org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:181)
 
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
 
    at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
 
    at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
 
    at java.lang.reflect.Method.invoke(Method.java:606)
 
    at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:636)
 
    at org.eclipse.equinox.launcher.Main.basicRun(Main.java:591)
 
    at org.eclipse.equinox.launcher.Main.run(Main.java:1450)
 
    at org.eclipse.equinox.launcher.Main.main(Main.java:1426)
 
Caused by: java.lang.NoClassDefFoundError:
com/systech/ge/client/dao/GlobalAngaben
 
    at
Gerentform_A4_1425317359080_722125.evaluate(Gerentform_A4_1425317359080_722125:215)
 
    at
net.sf.jasperreports.engine.fill.JREvaluator.evaluate(JREvaluator.java:250)
 
    ... 56 more

At the beginning i could use the compiled report without any problems in my Eclipse App.

In Eclipse all my data from the datasource is filled, but not in the report.

Searched for something similar but couldn't find a solution.

I'm using a plugin which contains the jar files.

Forgot the Code which causes the Error in Eclipse @fillReport():

JRBeanCollectionDataSource jrbcds = new JRBeanCollectionDataSource( Arrays.asList( fsureport ) );
 
JasperPrint jasperPrint;
Map< String, Object > parameter = new HashMap< String, Object >();
 
jasperPrint = JasperFillManager.fillReport( in, parameter, jrbcds );
david.vaupel's picture
Joined: Mar 5 2015 - 7:20am
Last seen: 4 years 7 months ago

0 Answers:

No answers yet
Feedback
randomness