Re: [NTLK] Avantgo

From: Steve Weyer (weyer_at_kagi.com)
Date: Fri Mar 01 2002 - 17:39:57 EST


> Date: Fri, 1 Mar 2002 08:21:24 -0800
> From: "Jim Anderson" <jiman_at_microsoft.com>
>
>
> Hmmm... It looks like I spoke too soon. I thought we could get
> AvantGo-like behavior by using NewtsCape's ability to compile and run
> NewtonScript in a web page to generate Newton books of a web page.
> However, it seems like NewtsCape behaves differently when doing a
> scheduled download. This actually makes sense, if you imagine that all a
> scheduled download is doing is loading the cache.
> I'm now playing around with using NewtsCape to generate a book
> from an external script, and I *think* this might work. The main thing
> I'm missing, right now, is a general way to schedule a piece of
> NewtonScript to run (i.e.: I don't want to just write a script that sets
> an alarm, I want to use something cron-like to run other scripts that I
> give it). Before I go off the deep end and write one, does anyone know
> if there is already something cron-like for the Newt? I bombed around
> Unna last night, but I couldn't find anything that looked likely.

in NewtonScript, you could use something like AddDelayedSend
assuming you knew how many milliseconds to wait before it should run

I wish Newt's Cape could help here. it has a crude callback mechanism which
is used when a URL is done xferring, and this is used to handle iterating
over a list of scheduled page xfers, and to handle subsequent dependent
xfers of images, frames, etc. the problem is that this callback is
basically the same for a command -- always "load", or always "do save pkg"
-- when in fact you'd like to combine: load everything, then save initial
set as packages. sounds simple in retrospect, but the way the code evolved
doesn't lend itself to this (and of course, there should be error handling
so if something didn't completely load successfully, it wouldn't
automatically generate an incomplete package, and generate a nice
transcript...)

(I'll glance at the code again tomorrow to make sure I haven't missed some
obvious hook for automating this...)

-- 
Steve
  weyer_at_kagi.com
Newton apps/tools: Newt's Cape, newtVNC, NewtDevEnv, Sloup, Crypto,...
  http://www.kagi.com/weyer/

-- Have you checked the FAQ lately? http://www.guns-media.com/mirrors/newton/faq/ This is the NewtonTalk mailing list - http://www.newtontalk.net To unsubscribe/manage: visit the above link. Questions: victor_at_newtontalk.net



This archive was generated by hypermail 2.1.2 : Tue Apr 02 2002 - 14:01:55 EST