LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Communicating with a web browser to download compressed folder

Solved!
Go to solution

I am currently sending a URL to call a .php file on a server. The php file is used to prompt a series of commands.  The server is located on another computer and the php operations normally send a compressed zip folder to my computer if using a browser.  It brings up the normal download dialog box acknowledging a download to my computer.  If I call the php file through LabVIEW, it sends back a binary file or text that contains all of the contents of a compressed folder - only in an unreadable format (see attached).  I believe the web browsers have something built in that acknowledges the files and brings up the download dialog box, that I am missing in my LabVIEW program. I am pretty new at communicating with a webserver in Labview. Is there any way for Labview to take this binary text and convert it to a zip?  Am I missing a step in order to download the zip folder to my computer with LabVIEW?  Attached is the script that I get in response in Labview.

0 Kudos
Message 1 of 4
(2,280 Views)
Solution
Accepted by topic author LabViewRookie08

All files are binary. It's a misconception that there are "text" files. Files are just a sequence of bytes, regardless of the extension. In your case you should be able to take the array you get from the method and wire it directly to a Write to Binary File function. Have you tried that?

0 Kudos
Message 3 of 4
(2,262 Views)

Prefect! Thanks.

0 Kudos
Message 4 of 4
(2,251 Views)