0

roUrlTransfer



Hi Whay types of strings and values are for the function AddHeader() if you want to download some files from: a ftp-server, an http-file-server or a web page? Once reached the server, that is you have a ping, What functions we should use to get a directory-file-list, or the html body-code? If the ...sync.xml files are not used in our scripts, once we get list of the files in the server folder, what functions we should use to move a copy of the file from the server to a temporay file on the SD card of the hd1010. What kind of errors might happen in this file download and how do we make second connection to server get the complete download, what functions we should use in the first and second atempt. Next step would be move the files from the sd temp folder, replacing autorun and other content files, deleting temp folder and make a reboot, but it is the only step i have a bit clear. Thanks.

1 comment

  • 0
    Avatar
    RokuLyndon


    You can add any string to the header. It's just included in the http headers. There are examples of this if you open the autorun script used by brightauthor, and search for addheader.

    You cannot use http to get folder list. You would need to include a file in the folder that you can download, and that should contain the folder list.

    You can use an http gettofile or asyncget to file to download a file. Http errors and result codes are in the object reference. If the file fails to download, you can restart by doing another httpget, you cannot continue an interrupted download.

    The brightscript reference document covers creating and deleting files, and copying.
Please sign in to leave a comment.