Is app running?
Is app running?
- Subject: Is app running?
- From: Brennan <email@hidden>
- Date: Fri, 6 May 2005 01:44:38 +0200
Hi folks,
I feel a bit dumb, because I feel sure this has been up before and I can't
find it in my archive.
Should be simple. I need to find out whether a specific app (in this case
QuickTime player) is running. At the moment I am using:
tell application "Finder"
(application processes whose name contains "QuickTime Player") is {}
end tell
This works, but is there a way to do this without using the Finder? (And
preferably without launching any other apps).
Maybe it's an old OS9 habit dying hard (where calls to the Finder had
significant performance overheads).
I am part of the way there with a shell script. I have some small working
chunks, but am a bit stuck piecing them together, for example:
do shell script "top -l1 | grep 'QuickTime*' | cut -f2 -d' '"
This returns pid if Quicktime Player is running, or "" if not, but may
return false positives. (i.e. Other users' copies of the app, or other
apps that start with the word 'QuickTime').
I may be barking up the wrong tree.
Is there another solution that I have overwoofed?
Brennan
_______________________________________________
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