我正在尝试在服务器上创建一个名称来自用户的新文件夹。这是我到目前为止所拥有的
display dialog "Please enter your augnet username" default answer "username"
set username to (text returned of result)
mount volume "smb://orgs.augsburg.edu"
tell application "Finder"
make new folder at "orgs.augsburg.edu/Information Technology/www/kb_images/Migration Testing" with properties {name:username}
end tell
我收到错误消息“无法生成类型项” 任何帮助深表感谢。谢谢!
答案 0 :(得分:0)
您有错误,因为:
1 - 此路径的类型为“posix path”, Finder 无法识别此类型,斜杠应替换为冒号
2-在Finder中使用字符串(路径)时,必须指定类(文件夹,文件,磁盘,...)
display dialog "Please enter your augnet username" default answer "username"
set username to (text returned of result)
mount volume "smb://orgs.augsburg.edu"
tell application "Finder"
make new folder at folder "orgs.augsburg.edu:Information Technology:www:kb_images:Migration Testing:" with properties {name:username}
end tell