FTP Download

Josep jmyepes at mac.com
Tue Feb 10 00:35:54 EST 2009


Hi,

I get socket timeout error, I put the libURLSetFTPStopTime 30 but nothing,
the same.

Any idea?

Salut,
JosepM

Sarah Reichelt-2 wrote:
> 
>> I'm trying to download a PDF file from one ftp site, but only obtain an
>> error. Why? The file is about 1Mb aprox. Trying these URL directly in the
>> browser the PDF is downloaded perfectly.
>>
>> I use this piece of code:
>>
>> on mouseUp
>>   libURLDownloadToFile \
>>
>> "ftp://<username>:<pass>@ftp.regio7.cat/regio7_manresa/R7M_01022009.pdf","regio7","status"
>> end mouseUp
>>
>> on status
>>   put the urlstatus of
>> "ftp://<username>:<pass>@ftp.regio7.cat/regio7_manresa/R7M_01022009.pdf"
>> into field fStatus
>>
>> end status
>>
>> Nothing. What I doing wrong? I need download every day a PDF file from
>> one
>> ftp and upload to another, and save a copy of the PDF in the local hard
>> disk.
> 
> 
> What error do you get?
> 
> One useful debugging tool is to create a scrolling field (called "Log"
> in the example below) and use it to show the FTP log.
>         libURLSetLogField the long name of fld "Log"  -- starts logging
> and
>         libURLSetLogField ""   -- stops logging
> 
> 
> Here is a general FTP download script:
> 
>     libURLDownloadToFile tURL, tSaveName, downloadDone
>     -- tURL = full FTP path
>     -- tSaveName is the full file path for the downloaded file to be saved
> to
>     -- downloadDone is the name of the handle to be called when the
> download is finished
> 
> 
> -- this callback handler is only used when the download has finished
> --
> on downloadDone pURL, pURLStatus
>     -- show completion message
>     put "Download complete: " & pURLStatus
> end downloadDone
> 
> 
> HTH,
> Sarah
> _______________________________________________
> use-revolution mailing list
> use-revolution at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your
> subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-revolution
> 
> 

-- 
View this message in context: http://www.nabble.com/FTP-Download-tp21925626p21928053.html
Sent from the Revolution - User mailing list archive at Nabble.com.




More information about the use-livecode mailing list