MelwinPhilip
MelwinPhilip

Reputation: 15

BIRT base64 image generation using xml input

My XML input will have a base64 encoded Version of an image. The image is dynamic in nature an cannot be embedded using image-embed image option in BIRT. I am using Version >4 BIRT. I tried the URI option With input as base64 but its not working in the preview of PDF. Can any body throw some lightssee how i added. dataimage tag is my base64encoded data

Upvotes: -4

Views: 1101

Answers (1)

MelwinPhilip
MelwinPhilip

Reputation: 15

Finally I am able to figure it out.

  1. The encoded data of xml needs to be decoded and passed on to a table row.
  2. org.apache.commons.codec.binary.Base64.decodeBase64(row["dcpimage"]).
  3. It will not appear in the template but will properly refelct in pdf and html preview mode

enter image description here

Upvotes: 2

Related Questions