• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Print Barcodes in JasperReport-iReport

 
Ranch Hand
Posts: 2206
2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am getting the following error when I try and print a jasperreport from my web app.

[5/6/11 15:53:42:903 CDT] 0000001f SystemOut O PDFReportGenerator:17 net.sf.jasperreports.engine.fill.JRExpressionEvalException: Error evaluating expression :
Source text : it.businesslogic.ireport.barcode.BcImage.getBarcodeImage(2,$F{VENDORCODE},false,false,null,0,0)

When I do print from the iReport IDE it works fine.

 
Ranch Hand
Posts: 333
1
Mac Eclipse IDE Safari
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
It could be that it's not finding the jar file or one of it's dependancies required to execute your it.businesslogic.ireport.barcode.BcImage.getBarcodeImage

I am assuming thats your code and it's returning a Image to be displayed by the report.

 
Steve Dyke
Ranch Hand
Posts: 2206
2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

David Garratt wrote:It could be that it's not finding the jar file or one of it's dependancies required to execute your it.businesslogic.ireport.barcode.BcImage.getBarcodeImage

I am assuming thats your code and it's returning a Image to be displayed by the report.



That appears to be the issue. However, I do not know what jar file it needs. I have placed the iReport.jar in my WEB-INF folder along with the barbecue-1.5-beta.jar and barcode.jar.
 
David Garratt
Ranch Hand
Posts: 333
1
Mac Eclipse IDE Safari
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I use a similar approach for my application - albeit a Swing desktop application rather than a web application. It's rather overkill but I normally include the entire lib directory that accompanies JaserReports distribution zip with my application. I probably don't need them all - but better safe than sorry.
 
I am mighty! And this is a mighty small ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic