Re: Quitting applications and applescript studio application
Re: Quitting applications and applescript studio application
- Subject: Re: Quitting applications and applescript studio application
- From: J Stewart <email@hidden>
- Date: Wed, 20 Apr 2005 17:45:00 -0400
On 4/20/05 at -0600 Martha I. Espinosa said this
>I'm having problems with the following applescript:
>
>tell application "System Events"
> set RunningApps to the name of every process whose visible is true
>end tell
>
>repeat with CurrentApp from 1 to (the count of text items in RunningApps)
> set WhichApp to (text item CurrentApp of RunningApps)
> if (WhichApp is not in {"Finder"}) then
> tell application WhichApp to quit
> end if
>end repeat
Try this and see if it suits you, mind the line wrapping.
--> cut <--
tell application "System Events" to set RunningApps to the name of (every process whose visible is true)
repeat with CurrentApp in RunningApps
if (contents of CurrentApp) is not "Finder" then tell application (contents of CurrentApp) to quit
end repeat
--> cut <--
JBS
--
I drive way too fast to worry about cholesterol.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden