Hello everyone,
I have an AppSheet app that manages a list of machines. Each machine has multiple characteristics, and I already have a document template where these fields are filled in.
What I want to achieve is:
-
Each row (machine) should generate its own PDF report using the template.
-
After I finish editing or updating the final values in my main table (for example, after confirming all data is correct), I want AppSheet to automatically generate all the individual PDFs at once — not one by one manually.
I already have a working template for individual reports, but I’m looking for the best way to trigger mass generation of all the PDFs (for every row) after final data confirmation — ideally from an automation, a bot, or a single button/action.
Has anyone implemented something similar or can suggest the most efficient approach?
Thanks in advance!
Assuming
-
When you mention you have a main table , we assume it is a different table from the Machines table.
-
In the Machines table you have a list of machines with each machine having its own row of data. The PDF template is based on this row of data for each machine.
If so, please try below.
-
Please add a physical column called something like [Run_Machine_Report] in the Machines table. The column type -Number, Initial Value 0, Please disable the Show_if for this column.
-
In the Main table , add an action type “Execute an action on a set of rows” with the following settings. In the expression Machines[Machine_ID] , MAchines is the name of the Machines table and [Machine_ID] is the name of the key column of Machines table. Please change with the actual names you have.
- Create an action called “Create Individual Machine Report” of type “Data” Set teh values of some columns in this row” in the Machines table with the details like below
The expression for the action [Run_Machine_Report}+1
Please hide this action.
- Create a bot on the Main Table with settings like below
Bot on the table Machines. The bot to run on updates to the table. The bot to have condition [_THISROW_BEFORE].[Run_Machine_Report]<> [_THISROW_AFTER].[Run_Machine_Report]
-
The step “Create Individual Report” in the bot would have the typical PDF generation step with ypur PDF template.
-
When the user taps on the “Create All Machine Reports” action in the Main table, the Individual reports will be created.
Please ensure there are just handful of machines and not hundreds of machine because the report will be generated for each machine .
Another alternative , if you do not wich to have on demand reports but just say daily once reports , you could use scheduled bots that say run in the evening or at the beginning of the work day etc.
1 Like