Adujust Google doc template display

Dear friends,

     In my app I want to create a dynamic template whenever I make a checklist so that I can display only tthe filtered items in my ChecklisDetail table. Here is a sample of my table used to create the PDF template :

ChecklistTemplateItemIdItemNameVehicleTypeCategoryCodeChecked
T-ITEM207FeuxCamion RigideTrucksA
T-ITEM208DétresseCamion RigideTrucksA
T-ITEM209ReculCamion RigideTrucksA
T-ITEM210RétroviseurCamion RigideTrucksA
T-ITEM211Pare-brise - 20 cmCamion RigideTrucksB
T-ITEM212PneumatiquesCamion RigideTrucksA
T-ITEM213GoujonsCamion RigideTrucksA
T-ITEM214FuitesCamion RigideTrucksB
T-ITEM215Ceinture de sécurité (3 points)Camion RigideTrucksA
T-ITEM216BâcheCamion RigideTrucksA
T-ITEM217Au moins une calleCamion RigideTrucksA
T-ITEM218Marche piedCamion RigideTrucksA
T-ITEM219Démarrage Moteur avec cléCamion RigideTrucksA

I want to display The items  vertically like in my template as follows:

eldderri_0-1742604137330.png

Currently I am using this code inside my google doc template:

<<Start: ORDERBY(FILTER("ChecklistDetail", [ChecklistID] = [_THISROW].[ChecklistID]), [ItemName])>>



<<[ItemName]>>

      

<<[Image]>>

      

<<[Checked]>>

      

<<[Code]>>

      

<<End>>

Your help is highly appreciated,

Best regards,

 

Solved Solved
0 37 757
1 ACCEPTED SOLUTION

Here is something you could try.

In order to divide the filtered data into different groups, each of which corresponds to the individual column, you need to have sequential numbers attached to the data.

One way to do it is to copy the filtered rows' key column to a separate table, say table "Report", which enables it to use its [_RowNumber] for this purpose.

Then for each column of your template you can use an expression like

<<Start: SELECT(Report[id], MOD([_RowNumber], 6) = 2)>>     ### = 2 should be changed to match the column
<<[id].[column of the original table]>>  ### This is a dereference expression
...
<<End>>

 Below is an example template that I tested with. Make sure that you enclose each column in a separate table cell and each cell height should be the maximum size for alignment.

TeeSee1_0-1742717834721.png

This is a sample report

TeeSee1_1-1742717860771.png

 

View solution in original post

37 REPLIES 37
Top Labels in this Space