Logo
My Account |  Site Map | Contact Us  
Welcome Guest Search | Active Topics | Sign In | Register

Insert dynamic image into template Options
Grant Hawkes
Posted: Friday, May 11, 2018 3:43:57 PM
Rank: Newbie
Groups: Member

Joined: 4/27/2018
Posts: 3
We are trying to insert images into an existing PDF template but we have not been able to find a way to do this. The designers added placeholders for the images to the template but when we look at the fields at runtime the type is PdfPushButtonField which does not appear to have any members to allow us to set the image. As a workaround we are considering creating a PdfImageContent object and inserting it onto the page however there does not appear to be any way to get the location of the field that we need to insert the image over. Can you please let us know if there are any ways to solve either of these problems by 1) setting the image on the PdfPushButtonField 2) getting the location and size of the field on the page, or 3) if there are any other recommended approaches to inserting a dynamic image onto a PDF template?
eo_support
Posted: Monday, May 14, 2018 10:03:55 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 20,365
Hi,

There is no way to do that. The recommended method for this kind of situation is to use a HTML template instead of a PDF template. HTML is much more maneuverable than PDF. When you wish to insert contents into the template, you can simply change the image Url in your HTML or insert an image element at a specified location. After that you would use the HTML to PDF converter to convert the HTML to PDF and get the updated PDF file.

Thanks!
Grant Hawkes
Posted: Monday, May 14, 2018 3:30:22 PM
Rank: Newbie
Groups: Member

Joined: 4/27/2018
Posts: 3
Thank you for the response. Do you plan to support this scenario in the future?
eo_support
Posted: Tuesday, May 15, 2018 3:36:46 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 20,365
We do not have any plan to support it in the near future. PDF is not designed for this kind of purposes thus the internal structure lacks straight forward support for such scenarios. We feel that even if we were to implement it, it would feel like we are twisting the arms of PDF standard --- we could be wrong on this, so if you have any additional information that suggest otherwise please feel free to share.


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.