From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Download a file from internet programmatically

Hi all,

 

I need to download a file from internet. I need to make programmaticcaly the action to click on the file link and download the file without the message poupup visualization.

 

Can you help me.

 

Thanks

0 Kudos
Message 1 of 14
(3,826 Views)

Hi Paolo,

 

use DatasocketRead as described in this very old KnowledgeBase entry!

 

without the message poupup visualization.

What are you talking about?

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 14
(3,818 Views)

When you try to download something from internet, the brawser ask you where you wnat to save the file. I don't wont this, i wont to save the file in a predeterminated path 

0 Kudos
Message 3 of 14
(3,814 Views)

Hi Paolo,

 

then do as suggested before.

You will receive a string from DSRead and you can save that string to any file(path) you like to…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 4 of 14
(3,809 Views)

Unfortunatelly it is not working,

 

do you have an example?

 

Thanks a lot

0 Kudos
Message 5 of 14
(3,805 Views)

Hi Paolo,

 

simplified example:

check.png

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 6 of 14
(3,802 Views)

Hi,

 

I try to be more specifics, this is my file url : http://...../Installer_RAT_v3_1_7.zip

I try to do like in your example, but the Data soked read blocks goes in timeout.

Do you know why?

 

Thanks.

 

0 Kudos
Message 7 of 14
(3,796 Views)

Hi Paolo,

 

is the file accessible with this URL?

Did you attach the "[text]" suffix as explained in the LabVIEW help for DSRead?

How long does it take to download the file? Does it take longer than the default timeout of DSRead?

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 8 of 14
(3,779 Views)

At the moment I have the same problem.

I've successfully used data socket to download a picture oder a pdf. But I don't understand what I have to change to download a zip file. Usually when you open a website there is a link which lead to an pop up, asking where you want to store the data.

I've attached some examples. Maybe I just need a working url for the data socket

Download All
0 Kudos
Message 9 of 14
(3,778 Views)

Hi all,

 

yes the time is enought but i didn't get the download.

0 Kudos
Message 10 of 14
(3,760 Views)