Applescript to find application path from partial app name? How do I get the path to a running application using part of the app name. (eg. 'Acrobat' in 'Adobe Acrobat Reader DC') This is what I tried but it's incorrect. (Note: Not sure if it changes if multiple instances are running, but I only want a single POSIX path returned)
tell application &quot;System Events&quot;,
  if (get name of every application process) contains &quot;Acrobat&quot; then
    return POSIX path of (path to ((get name of every application process) contains &quot;Acrobat&quot;))
  end if
end tell
The following example AppleScript code assumes you only have one application running that contains &quot;Acrobat&quot; in its name, otherwise you'll need to process the list returned from System Events in a repeat loop.
tell application &quot;System Events&quot; to ¬
    set appAcrobatList to the ¬
        name of every application process ¬
        whose background only is false ¬
        and name contains &quot;Acrobat&quot;

if appAcrobatList is not {} then ¬
    return POSIX path of ¬
        (path to application ¬
            (first item of appAcrobatList))