Document not downloading using Asynchronous call

0
Hi All,   I have a "ACT_GeneratePDF" Microflow and I am using CommunityCommons module's JavaAction 'executeMicroflowInBackground' to call my Microflow. I see the PDF is getting generated but the 'Download File' action at the end of the Microflow doesn't do anything. However if I call this Microflow as a Sub in my Parent flow then the document is downloaded. Can someone help me with this issue. Appreciate the time.
asked
1 answers
1

If you want to allow a user to continue working while generating the document, you could do something like this:

 - In the generate PDF flow you create the object that will hold the PDF file,

 - Set a 'in progress' status on this object and commit it.

 - Generate the PDF in the background. Once that has successfully completed, set a 'done' status (furthermore, if an error occurs, you can set a 'failed' status).

 - In the user interface of the user, you can show a Data Grid of the object you created. In this grid, the user sees the status of the document (so 'in progress', 'done' or 'error'). You can add a refresh timer of e.g. 30 seconds, so that the status refreshes automatically when it changes.

 - If the document is 'done', the user can download it.

answered