Download files
Question

Hi,

I saw many posts about downloading files, but I still didn't get how to do a very simple task: I just want to have a button on my reactive web application to download a file (any format, like PDF, JPG, TXT, XLS, DOC, PPT, ZIP, etc) from a known URL, i.e. https://images-na.ssl-images-amazon.com/images/I/51NV8Uil7wL._AC_SY200_.jpg . The URL wil be hardcoded, it's not a value of database field.

How is the simplest way to do this? Thanks


mvp_badge
MVP
Solution

Hi Marcelo,

You can achieve the mentioned requirement by using GetRequest_Submit server action defined in HTTPRequestHander API Module

See this sample app

Please find the attached .oml file


Hope this helps you!


Regards,

Benjith Sam

DownloadExternalFileReactiveDemoApp.oml

Is this applicable with reports ?

Reports is located in other screen/espace

I've tried this but it returns this error
"The underlying connection was closed: Could not establish trust relationship for the SSL/TLS secure channel."

mvp_badge
MVP

Hello Marcelo.

If you simply place the link there, clicking will sent the user to the image address.

To force download you can always:

1. Get the content with HttpBinaryGet (an extension).
2. Set the download action with such content and the name you want.

You just need to create a server action to bridge the extension and the screen action.


mvp_badge
MVP
Solution

Hi Marcelo,

You can achieve the mentioned requirement by using GetRequest_Submit server action defined in HTTPRequestHander API Module

See this sample app

Please find the attached .oml file


Hope this helps you!


Regards,

Benjith Sam

DownloadExternalFileReactiveDemoApp.oml

Is this applicable with reports ?

Reports is located in other screen/espace

I've tried this but it returns this error
"The underlying connection was closed: Could not establish trust relationship for the SSL/TLS secure channel."

Nuno Reis & Benjith Sam,

That works! Many thanks!!!

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.