Jump to content

show blob (images like jpg /gif) on jasper report


rbojja

Recommended Posts

  • Replies 3
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

You should declare a report field of type java.awt.Image that corresponds to the DB blob column, and use the field value as image expression:

<field name="BlobColumnName" type="java.awt.Image"/><image>  <imageExpression class="java.awt.Image">$F{BlobColumnName}</imageExpression></image>

HTH,

Lucian

Link to comment
Share on other sites

Thank you Lucian,

can you give a sample demo file for reference.i didnt find any in jasper reports demo files.

I created a textfield.For this i didnt find any text field expression class of type "java.awt.Image".

 

I am using iReport tool of 2.0.5 version.

 

can you correct me if i am going wrong.

Link to comment
Share on other sites

I'm afraid I don't have a full sample that illustrates images from blob columns.

I don't understand why you are talking about text fields.  You need to create an image element in order to display an image, text fields are for texts.  Once you create an image element, go to Properties/Image, and set the image expression and class as shown in the attached screenshot.

Regards,

Lucian

Link to comment
Share on other sites

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...