You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
use AppleScript version "2.4" -- Yosemite (10.10) or lateruse scripting additions-- http://veritrope.com/code/toggle-an-app-on-off--ENTER THE NAME OF THE APP --THAT YOU WOULD LIKE TO TOGGLE--IN THE PROPERTY BELOW...--property app_Name : ""------if appIsRunning(app_Name) then-- do shell script "killall " & (quoted form of app_Name)--else-- do shell script "open -a " & (quoted form of app_Name)--end if----on appIsRunning(appName)-- tell application "System Events" to (name of processes) contains appName--end appIsRunningtell application "System Events" set frontProcess to first process whose frontmost is true set visible of frontProcess to falseend tell