2011-10-26 18 views
2

XCodeには、ローカルネットワークコンピュータ上のiTunesにいくつかのコマンドを送信しようとしているCocoa-AppleScriptプロジェクトがあります。何らかの理由で、これは動作します:リモートマシン上のiTunesを搭載したAppleScript

tell application "iTunes" of machine "eppc://user:[email protected]" 
    playpause 
end tell 

しかし、これにはないが:

set remoteMachine to "eppc://user:[email protected]" 
tell application "iTunes" of machine remoteMachine 
    playpause 
end tell 

私はエラーを取得「リモートマシンを見つけることができません。」何か案は? named修飾子を追加

答えて

1

OK、私はそれを考え出した、またはそれを行うには、少なくとも一つの方法。

set theRemoteApp to application "eppc://user:[email protected]/iTunes" 
using terms from application "iTunes" 
    tell theRemoteApp 
     playpause 
    end tell 
end using terms from 
0

試してみてください。

set remoteMachine to "eppc://user:[email protected]" 
tell application "iTunes" of machine named remoteMachine 
    playpause 
end tell 
+0

残念ながら、これは機能しませんでした。他のアイデア? – Jesse

関連する問題