I have a function that sends a batch of Data to Docugenerate using the generate document codeless block. This works and I can download the document successfully from the Docugenerate . I would like to be able to initiate a download of the document on a button press within my application.
I am still learning learning this platform and am only using codeless blocks.
I am pretty sure that this can be done using the ‘get document’ block but can’t figure it out.
Any help will be appreciated.
Hello @Richard_Lewis
What is the generate document codeless block?
How can I play with it?
Regards
Hi Viktor
It is from the Docugenerate Api on marketplace.
The first image is what works and I can download this as a pdf from the docugenerate website, however i think I should be able to use the block in the second image within my Backendless App to start a Download.
Regard
Hi Richard,
A few questions to help me understand where you are with it:
- Do you already have a UI page?
- is there a button on the page?
- Have you created an event handler for the
On Click
event for the button?
- Have you found the block for the DocuGenerate service in UI Builder?
Regards,
Mark
Hi Mark. the images below is what I have got. The generate cp12 button is linked to the image block shown in my first post and works.
I have tried the get document setup below, but that doesn’t seem to do anything.
Both buttons are in the same cell as you can see.
Thank you. Have you done any diagnostics or debugging to determine if the logic runs when the button is clicked? And if so, what the service returns for the request?
Thanks Mark
To be honest I am quite a novice and have been seeing if its possible to build something useable with UI Builder without having to understand too much about the code. Just using Logic…it’s a steep learning curve!
the image below is from my latest attempt and I think it is implying an error but I don’t understand it.
Hi Richard,
It looks like the logic you created results in an error. Please see the following page for information on how you could debug the logic (it references “mobile”, however, the same instructions apply to desktop browsers):
https://backendless.com/docs/uibuilder/ui_debugging_on_mobile.html#client-server-integration-network-monitoring
Regards,
Mark
Thanks Mark,
I will have a read and see how I get on.
Regards
Richard
I have done a bit more research and realised that the value returned from the generate block is a list of which i needed to extract a url. So this logic works to create and down in one action.
Thanks
You are welcome! Let me know if you’d like to see how you could simplify it even further 