Automation 使用Applescript在Photoshop中打开文件
我正在尝试使用Applescript在photoshop中自动执行任务 尝试打开文件时:Automation 使用Applescript在Photoshop中打开文件,automation,applescript,photoshop,Automation,Applescript,Photoshop,我正在尝试使用Applescript在photoshop中自动执行任务 尝试打开文件时: tell application "Adobe Photoshop CS5" -- Open the first image set filePath to alias "Users:jameshale:Pictures:DSC_1273.jpg" with timeout of 5 seconds open filePath as Camera RAW end timeout end te
tell application "Adobe Photoshop CS5"
-- Open the first image
set filePath to alias "Users:jameshale:Pictures:DSC_1273.jpg"
with timeout of 5 seconds
open filePath as Camera RAW
end timeout
end tell
结果是一个错误:
error "Adobe Photoshop CS5 got an error: Can’t get alias \"Users:jameshale:Pictures:DSC_1273.jpg\"." number -1728
我做错了什么
-J别名路径在根目录中包含HD名称。所以你需要把你的一行改成这个
// Replace Macintosh HD with your HD name
set filePath to alias "Macintosh HD:Users:jameshale:Pictures:DSC_1273.jpg"