Applescript Applscript工作流无法从菜单中工作

Applescript Applscript工作流无法从菜单中工作,applescript,automator,Applescript,Automator,我不熟悉苹果脚本。我正在尝试编写一些脚本,让您使用全局热键在iTunes中向前/向后跳过5秒。下面是向后跳的脚本: tell application "iTunes" if player state is stopped then return try set player position to (get player position) + (-5) end try end tell 当从Automator中运行时,它工作正常,iTunes的响应是倒带5秒。我已经成功地将它保存为

我不熟悉苹果脚本。我正在尝试编写一些脚本,让您使用全局热键在iTunes中向前/向后跳过5秒。下面是向后跳的脚本:

tell application "iTunes"
if player state is stopped then return

try
    set player position to (get player position) + (-5)
end try
end tell
当从Automator中运行时,它工作正常,iTunes的响应是倒带5秒。我已经成功地将它保存为服务,它位于/Library/Services中

但是,当我从“服务”菜单运行脚本时,什么也没有发生


有什么想法吗?

重新启动我的电脑解决了这个问题