Where can I learn about Applescript and Revolution?

Jan Schenkel janschenkel at yahoo.com
Wed Oct 9 15:09:01 EDT 2002

--- RGould8 at aol.com wrote:
> I'm trying to find "Applescript" in the Revolution
> documentation, and how to 
> go about making Applescript calls and reacting to
> Apple Events - - - can 
> anyone point me to a web-site or tell me where in
> the docs I could find more 
> details on how this is done?

Hi there, and welcome to RunRev.

If you want to execute a piece of AppleScript code,
use the 'do' command. Example:

  put "tell application" && quote & "Finder" && \
    quote & return into tAppleScript
  put "select the startup disk" & return after \
  put "end tell" after tAppleScript
  do tAppleScript as AppleScript

If you want to capture AppleEvents being sent to your
RunRev application, you'll need to handle the
'appleEvent' message. Example:

on appleEvent pClass, pID, pSender
  answer "Received AppleEvent of class" && \
    pEventClass && "and ID" && pEventType && \
    "from" && pSender
  pass appleEvent -- move it up the message chain
end appleEvent

To learn more about AppleScript in general, visit the
website http://www.applescriptcentral.com

There are a few entries in the use-revolution archive,
so you might want to search around there as well.

Hope this helped,

Jan Schenkel.

"As we grow older, we grow both wiser and more foolish
at the same time."  (La Rochefoucauld)

Do you Yahoo!?
Faith Hill - Exclusive Performances, Videos & More

More information about the use-livecode mailing list