I have an old OS 9 applescript to determine if a given application is running.
Could someone give me some guidance as to what the equivalent script would look like
in an OS X environment? Thanks.
The old script is:
on run
if (isRunning(“LXR”) is false) then
quit
end if
end run
on isRunning(AppName)
tell application “Finder”
set runningApps to “About this Computer”
end tell
set numberOfApps to count of items of runningApps
repeat with i from 1 to numberOfApps
try
set nameOfApp to name of item i of runningApps as string
display dialog nameOfApp
if (nameOfApp contains AppName) then
return true
end if
end try
end repeat
return false
end isRunning
Kelsey