教科书中的一个练习令我难过,示例脚本:
tell application "Finder"
tell folder "AppleScript" of folder "Applications"
set file_list to name of every item
set time_folder_was_created to creation date
set time_folder_was_modified to modification date
end tell
end tell
脚本编辑器一直给我这个结果:错误" Finder收到错误:无法获取文件夹\" Applications \"。"从文件夹"应用程序"
编号-1728这是否与过时的进程或应用程序文件夹的OS 10.11安全性有关,或者我没有看到它。
答案 0 :(得分:0)
文件夹$(CXXFLAGS)
是Applications
startup disk
或使用相对路径
tell application "Finder"
tell folder "AppleScript" of folder "Applications" of startup disk
set file_list to name of every item
set time_folder_was_created to creation date
set time_folder_was_modified to modification date
end tell
end tell