Script for download file

Use this Forum to post your “How to …” questions about your use of aXes. This is not a technical support forum. Both the aXes Support Team at LANSA and other aXes customers may answer your questions. LANSA cannot guarantee the accuracy of any information posted by customers.

Moderator: jeanmichel

Post Reply
RobCol
Posts: 12
Joined: 17 Mar 2021, 22:25

Script for download file

Post by RobCol »

Hello,
what script can I use to open a download file from an IFS path?
I would like to use it at the click of a button.
thank you very much
User avatar
Dino
Posts: 88
Joined: 19 May 2017, 08:29

Re: Script for download file

Post by Dino »

Hi RobCol,

Once you bring the button to the screen, you can add for example this code in the onClick:

Code: Select all

var hiddenElement = document.createElement('a');
hiddenElement.href = '/ts/skins/images/examplephoto.gif';
hiddenElement.target = '_blank';
hiddenElement.download = 'examplephoto.gif';
hiddenElement.click();
to download in this case a sample gif ur other file in the IFS:
axesdown.png
axesdown.png (105.26 KiB) Viewed 4786 times
Post Reply