Bulk Print PDF

Hi, I would like to have a function to print many PDF at one time. User just need to select the data from Data Grid and then click the bulk button to print the PDF.
2 answers


If you selecting multiple object from datagrid and passing it to a document template to print the PDF, then you might try the following

  1. Pass the list of objects selected to microflow
  2. Create a list of file document outside your loop
  3. Loop through the objects and generate document
  4. Add the generated document to the list
  5. Use MergeMultiplePdfs from community commons, pass the list along with a new file document for merged document


Then you can download the PDF. Please note, if you are selecting a lot of objects, this might have performance issues.

So, its better to see if you can do this in the background using modules like process queue 1 by 1 and merge it finally.

Or simply restrict the amount of items being processed for bulk printing.


Here you can find the basics of document generation: https://docs.mendix.com/refguide/generate-document

In order to execute this for a list; pass the list in the microflow and loop through them.