I want to download the page in PDF format, the button group of the current page will filter the data in the list, and the requirement is to click different buttons to download the pdf containing the corresponding data list. My idea is to modify the URL of the current page when clicking different buttons, and then use the URL under each button to download the PDF. But each download is the same page, I hope you can help, or share your thoughts, thank you
Hi Lingchen,
I made some changes like in DownloadOnClick action.Please check the updated oml attached.Check the Demo hereRegardsKrishnanand Pathak
First of all, thank you so much for your help,I modified according to the part you modified, but I made a mistake. Is it my problem?
There is no problem in downloading the file you modified,But I wonder what went wrong with mine.
OnReady action is missing in your.
Which will assign the domain local variable.
Also change the Url to local variable from input parameter
It has been solved, thank you very much, good life is safe, but there is a problem with the downloaded PDF layout, I will try to solve it first, wish you a happy life
As you said your issue is solved then Mark the answer as solution. It would be helpful for others also
sure!
Hello, I would like to ask where the problem occurred in my previous practice, the URL was not updated, didn't I get the updated address when downloading? Did you add the On Ready event so that the page would execute Render every time I clicked the button? Will it still be Ready? I'm a little confused about this part. I don't really understand it
Hi,Format of URL expected was different by PrintToPDF.OnReady is only to assign the domain variable using GetRequestDomain. Yes, we can also do this at OnInitialize as it an initialization.If you want more details regarding screen events like OnInitialize, OnReady . Then check the below official documentation.https://success.outsystems.com/documentation/11/developing_an_application/implement_application_logic/screen_and_block_lifecycle_events/RegardsKrishnanand Pathak
Thank you,Krishnanand Pathak , I understand. I have learned about the life cycle of OnReady through debug, but I was not familiar with many places at the beginning. Thank you very much for taking time to answer my questions.