使用以下代码:
tell application "Finder" to reveal every item of theFiles
当 theFiles 包含单个文件时有效,但当它包含多个文件时,我得到:
error "Finder got an error: AppleEvent handler failed." number -10000
我究竟做错了什么?我只是想在 Finder 中突出显示文件列表。
使用以下代码:
tell application "Finder" to reveal every item of theFiles
当 theFiles 包含单个文件时有效,但当它包含多个文件时,我得到:
error "Finder got an error: AppleEvent handler failed." number -10000
我究竟做错了什么?我只是想在 Finder 中突出显示文件列表。
这似乎有效:
tell application "Finder" to reveal theFiles
我正在查看的一个示例显示“......揭示......的每一项”。我不确定他们是否有错误或 AS 发生了某些变化。
这似乎工作正常
tell application "Finder"
set theFiles to entire contents of folder of (choose folder)
reveal every item of theFiles
end tell