automating a task

Brian E. Warshawsky bwarshawsky at fastmail.fm
Mon Apr 12 16:26:52 EDT 2004


Hey everyone.  I just started using Revolution a couple of days ago, and
am trying to write a couple useful apps before my trial runs out so I can
convince my boss to buy me a full copy.   I want to write a simple app to
automate the task of retrieving log files from a bunch of different ftp
servers at the same time every night.  I've tried several commands and
syntaxes, but nothing is working.  

I've tried:
repeat forever
get the time
if the short system time is 12:00 AM then
libURLDownloadToFile "ftp://username@password@mysite.com/testing.txt",
TFlog.txt
else end if

I've also tried:

repeat forever
wait 5000 seconds
libURLDownloadToFile "ftp://username@password@mysite.com/testing.txt",
TFlog.txt

and:
if the short system time is 12:00 AM then
libURLDownloadToFile "ftp://username@password@mysite.com/testing.txt",
TFlog.txt
else repeat until the short system time is 12:00 AM

I've tried the last one with and without a repeat forever at the
begining.  I've also tried a host of others.

I don't get copiler errors when I apply these changes, and I've tried
writing this in the card script and in the stack script, but nothing will
work.  I can make it work if I set the libURLdownloadtofile to execute
after i click a button, but that's hardly automatic!  I'm not sure if
this isn't working because I'm putting the code in the wrong script, or
if I just don't know what I'm doing.  Either way, I'd greatly appreciate
some help here.

Thanks in advance,

Brian 
-- 
  Brian E. Warshawsky
  bwarshawsky at fastmail.fm

-- 
http://www.fastmail.fm - mmm... Fastmail...


More information about the use-livecode mailing list