505
Views
4
Comments
how to download a file with filepath

Hi All,

Can anyone suggest how to download the file from file path in reactive,downoad widget accepts binary but Binary not available.

2023-04-16 15-25-31
Krishnanand Pathak

Hi @ujwala T
Use File_ReadBinary provided by FileSystem extension to read the file from path then pass output to download node as shown in belew image to download the content.

Also check the below link
https://www.outsystems.com/forums/discussion/41051/download-file-from-certain-directory-in-the-server/#


Regards

Krishnanand Pathak



2024-09-12 02-43-38
Deepsagar Dubey

Hi ujwala

You can refer Outsystems documentation for more knowledge on downloads 

https://success.outsystems.com/documentation/11/developing_an_application/use_data/download_a_file_through_browser/ 

Thanks

Deep

2022-02-25 19-42-59
Srinivas K Singadi

Hello ujwala T

if you have the file path and want to download the file using the Download widget, you can do the following steps:

Create a server action that returns the binary content of the file from the file path. You can use the FileReadBinary() function to read the binary content of the file.

Create a screen action in your Reactive Web Application and add a Download widget to it.

Set the Source property of the Download widget to the server action you created in step 1.

Set the FileName property of the Download widget to the name of the file you want to download.

Set the ContentType property of the Download widget to the appropriate MIME type for the file you are downloading.

On your screen, add a button or link and set the OnClick event to the action that triggers the Download widget.

When the user clicks the button or link, the Download widget will call the server action, get the binary content of the file, and initiate a download of the file with the specified file name and content type.

2023-12-14 09-56-57
Yogesh Javir

Hey,

Hope below link will help you.

https://stackoverflow.com/questions/3916191/download-data-url-file


Thanks

Yogesh

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