Close non Rev apps via Rev apps?

Garrett Hylltun garrett at paraboliclogic.com
Sat Jul 8 20:43:44 EDT 2006


Sarah Reichelt wrote:
[snip]
>> I don't think it's possible to close the program directly from my Rev
>> app, but is it possible via AppleScript?
> 
> 
> Here is an AppleScript that will check if Mail is running & quit it if so.
> 
> tell application "Finder"
>     if exists application process "Mail" then
>         tell application "Mail" to quit
>     end if
> end tell
> 
> Just replace "Mail" witht he name of your app and it should work for
> anything. The check is necessary because a "tell" will open the app
> first before doing the rest, which you don't want if you are only
> trying to quit it anyway.

Thank you Sarah :-)


-Garrett



More information about the use-livecode mailing list