問題は補助具ではありません。AppleScript は、ウィンドウを持つことができないプロセスのウィンドウにアクセスしようとすると、そのエラー コードを誤って返すようです (私の場合は「Google Chrome Helper」でした)。
エラーをキャッチする必要があります。これは私のために働く:
tell application "System Events"
set procs to processes
set windowPositions to {}
repeat with proc in procs
try
if exists (window 1 of proc) then
repeat with w in windows of proc
copy w's position to the end of windowPositions
end repeat
end if
end try -- ignore errors
end repeat
end tell
return windowPositions
{{1067, 22}, {31, 466}, {27, 56}, {63, 22}, {987, 22}} などの座標ペアのリストを返す – それはあなたが取得しようとしていたものですか?