Applescript fails with error (-600) when launched over ssh on Mavericks

前端 未结 11 1656
孤城傲影
孤城傲影 2020-12-05 14:34

I\'ve tried searching for this, and have seen others with similar problems but don\'t seem to have found an answer anywhere....

I have an AppleScript that I am tryin

11条回答
  •  悲&欢浪女
    2020-12-05 14:58

    @benmarbles code seems to be missing something at the end of line 2 -- it won't even compile.

    Anyhow, I've seen the same issue with "Image Events" and I solved it with a simplified version of that script. Here's how I handle it:

    tell application "System Events" to set thePID to (unix id of process "Image Events")
    set killCMD to ("kill -9 " & thePID) as text
    do shell script killCMD with administrator privileges
    

    Replace Image Events with System Events to kill that process instead. The System Events process keeps itself alive, so there's no need to do anything to relaunch it.

提交回复
热议问题