cancel
Showing results for 
Search instead for 
Did you mean: 

Dynamic images in ADOBE forms

Former Member
0 Kudos

Hi All

Please help me to solve this problem.I have a requirement of printing dynamic image on my PDF depending on a specific condition.

At present before building my XML , from ABAP side I am getting the corresponding mime object and converting it into XSTRING,

after that into base64 and I am including it in image table of XML.

call method mime_repository->get

exporting

i_url = url

importing

e_content = mime_xstring.

lv_string = mime_xstring.

call method cl_http_utility=>if_http_utility~encode_base64

exporting

unencoded = lv_string

receiving

encoded = ls_image-wa_image-url.

At destination point in javascript depending on the specific condition I am able to get the base64 string but when I am assigning this value to Imagefield it is not displaying any image.

URL.rawValue = xfa.form.data.variables.VAR_IMAGE_VALUE.value;

(Where VAR_IMAGE_VALUE is a global variable with corresponding base64 string value for image)

But when I assign a staticimage value to this Imagefield it is working.Please help me to display a dynamic image from XML.

Thank you.

Giri.

Accepted Solutions (1)

Accepted Solutions (1)

ChrisSolomon
Active Contributor

How many fricking times can this same crazy question be asked?!?!?!

SEARCH is your friend!!

Also, there is a perfectly good example of this if you search Google! OTHER people outside SAP have already answered this in OTHER Adobe form sites.

Former Member
0 Kudos

Hi Chris

You are absolutely right there are lot of responses for the same topic but I think I am doing something wrong in my case.

I went through lot of posts and still not getting it right.I am still trying to resolve my problem.

I went through the 2 links mentioned by Otto and still haven't get it right.

Thank you.

Giri.

Former Member
0 Kudos

Hi All

I got it working.I was limiting the length of the text field at form level that is the reason not getting dynamic images.

I haven't changed any of my logic except unchecking the tick box for limiting the length.

Thanks Otto and Chris for your responses.

Giri.

OttoGold
Active Contributor
0 Kudos

I have checked the code. What I don´t understand:

why do you use JS for bidning? I would create several image fields, bind them to the context variables through tab binding, and use JS to manipulate their presence. This way I would be sure my JS "binding" is not a problem.

I also wonder if you have checked the trace if the picture data stream is present in the XML data stream/ context values.

Otto

Answers (1)

Answers (1)

OttoGold
Active Contributor
0 Kudos

When you need to send a picture into the offline form: and

Otto