How to pass variable data between AppleScript and Revolution?

RGould8 at aol.com RGould8 at aol.com
Wed Oct 9 16:16:01 EDT 2002


Jan/Ken & the listserve,

     Thanks so much for your assistance in answering my AppleEvent 
questions.  Your answer has prompted me to think more about how I was 
approaching the issue, and now I'm wondering if I even need to use 
AppleEvents at all, if I can execute the AppleScript right from within 
Revolution.

     Ok, last Applescript question for the day, I believe.   I've learned so 
much in the past 1/2 hr on this list - - it's been great.

     My ultimate goal is to write a Revolution app that:

1)  Launches Internet Explorer to a specific URL   ( The web-pages have lots 
of tables, and I need e-commerce security on these pages, otherwise I'd 
attempt displaying the pages in Revolution itself)
2)  Detects when the user has landed on a certain page
3)  Send the html text of that page back to Revolution for parsing

I presently have an AppleScript that runs an "idle" loop, constantly checking 
the title of the page within Internet Explorer, and when it detects the 
specific page I'm looking for, Applescript captures the HTML text from that 
page.

I'm wondering if I can eliminate the whole need to "sublaunch" the 
AppleScript App as a separate "self-running app", and just run the script 
itself within Revolution.

There are 3 gotchas that I can think of:

1)  Can I use an on-idle handler within Revolution that launches an 
AppleScript, so that I don't have to use Applescript's on-idle handler.  
Would one be any better than the other?

2)  Once AppleScript captures the html text from Internet Explorer, how can I 
get that data back to a variable in Revolution?  Is there some sort of 
variable-passing language between Applescript and Revolution?   Or are 
AppleEvents the solution for passing variable data between AppleScript and 
Revolution?

3)   Is there a way to get a fairly large Applescript into a "do script" 
command?   The one-line-at-a-time-&-return method could get rather painful.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.runrev.com/pipermail/use-livecode/attachments/20021009/fb06b379/attachment.html>


More information about the use-livecode mailing list