Posted 15 September 2022, 5:45 am EST
Hi,
I’m actually testing Grapecity to generate PDF from WORD template after injecting JSON.
It’s working really fine but I don’t find how to insert an image in the Template from base64 json.
Forums Home / Document Solutions / Document Solutions for Word
Posted by: vincent.boyer.ucf on 15 September 2022, 5:45 am EST
Posted 15 September 2022, 5:45 am EST
Hi,
I’m actually testing Grapecity to generate PDF from WORD template after injecting JSON.
It’s working really fine but I don’t find how to insert an image in the Template from base64 json.
Posted 16 September 2022, 4:18 am EST
Hello Vincent,
Please find the attached sample which shows how you can insert an image in the Template from base64 json.
If you need any other help, please let us know.
Regards,
Prabhat Sharma.
Posted 16 September 2022, 4:18 am EST
sample
DataTplSimpleListJson.zip
Posted 5 October 2022, 2:48 am EST
Thank you !
Posted 16 November 2022, 7:19 am EST
Hi,
So, I’m keeping up my tests about injecting data with json.
For the picture :
{{ds.pic}:image()} is ok
But there is a way to resize the picture ?
*{{ds.pic}:image().resize(120,120)} *
Posted 16 November 2022, 7:52 am EST - Updated 16 November 2022, 7:58 am EST
Hello Vincent,
Yes, the image can be resized. Please use the below-given template for the same.
{{ds.pic}:image(120,120)}
We have also modified the last attached sample implementing the same.
Regards,
Prabhat Sharma.
DataTplSimpleListJson_Mod.zip
Posted 16 November 2022, 8:28 am EST
Thank you.
There is a page with all these template function ?
Posted 16 November 2022, 8:39 am EST
Yes, please check the following documentation and demo links for the same:
https://www.grapecity.com/documents-api-word/docs/online/data-templates.html
https://www.grapecity.com/documents-api-word/demos/report-templates
https://www.grapecity.com/documents-api-word/demos/report-templates/data-tpl-image/code-cs
Posted 16 November 2022, 11:53 am EST
Thanks