Action button to create and download PDF & Embed image in email body template for PDF

Hello,

  1. I want to give an action button by clicking it, a user can generate and download PDF. How do I do it?

  2. I have a reference table for company name and its log. On the basis of company code in the transaction, I want to embed company logo image into the email body template for PDF. How do I do it? When I wrote select statement, it did not bring the logo image rather it printed selected column value in the PDF.

Regards,
Rajan

0 16 3,806
16 REPLIES 16

in the workflow template you have to upload a google doc template of the format you want the data to be in along with the company logo.

Then create a action button with option selected to change the value of a certain columnโ€ฆwhich in turn should trigger the workflow to send email to the preset id.

You may want to take a look at the topic Sending Email from an Action Button in the article below

In the workflow pane, you could use actionโ€™s reaction as โ€œSave Fileโ€

3X_e_e_ee608c06c625a43416bd40adbc76a0b16850c19f.png

Could you please elaborate more?

There is a master table โ€œCompanyโ€ it has company code and a log image columns. Another table as โ€œTransactionโ€ which is Company Code and other columns.

Now, I want to give a button to the user when he/she clicks on that button, it should generate a PDF of the transaction with a company logo on the top of the page. I already use google doc as email body template.

Hope, I am able to explain.

Rajan

Thank you.

I believe, this can be generated with the suggestion of Sending Email from an Action Button on Transactions table.

For company logo not appearing, could you please elaborate the relavant template expression and column types of image columns in both the tables and whether Company table is referenced by the Transactions table.

could he create a table called pdf and have the same columns as the main table. Then create a button using action to copy the data from the  main to the pdf table and have a work process that is triggered by add on the pdf table to create and save the file or send it through email?.  that will have a one button action

Hello,

Master table.

Transaction Table.

3X_2_3_236f5b4ea4b0a088a914c652528df4e870f1e3e6.png

Images stored on drive.

The email body template which is saved as PDF to send as attachment in the email. But it is not embedding image in the PDF. Rather captures column name only.

How to embed logo image into the PDF? So that when user downloads PDF from mail and opens it has company logo image on the top of the page.

Thank you. Can you reference NFA Company table into Credit Note Requests table? In that case you could pull the company logo into template ( or Credit Note Requests table as well ) with a dereference expression like [Company Code].[Logo]

Steve
Platinum 4
Platinum 4

There is no way to do this with one click.

PDF files are generated by workflows or reports. Workflows and reports are performed by AppSheet servers, not by the app itself. Workflows are performed when a sync occurs between the app and the server.

Generated PDF files are saved to the appโ€™s cloud storage. To access the generated PDF file in cloud storage, the app must present and the user must click on a link to the file. I canโ€™t speak from experience, but I believe users must open the PDF then save; I donโ€™t think thereโ€™s a way to download directly without first opening.

Good catch @Steve, I missed the word โ€œdownlaodโ€ and assumed it as โ€œsaveโ€( in the drive).

Ok. But a PDF can be mailed on some action. In that scenario, how to embed an image a I explained the transaction scenario in earlier post?

If you are unable to reference the Company table, then please try with an expression as below to pull the logo into the template.

<< ANY(SELECT(NFA Company[Logo], [Company Code]=[_THISROW].[Company Code]))>>

Hello,

As per your above solution, the image appeared in the email body, but it did not appear in the PDF.

Template is as below.

PDF is as below.

Now, it should appear in the PDF too.

Thanks.

The expression appears to be correct. May be you wish to ensure changes were saved to the template before report was run by running the report once more.

Thanks a ton Suvrutt.

Logo appeared in the PDF tooโ€ฆ

Regards,
Rajan

Great. Thank you for the update.

it can be useful, although it is in Spanish

Top Labels in this Space