set fold to "/Users/Test/Desktop/"
set file to "/Myfolder/Hi.txt"
如何将这两个变量连接起来,将文件路径设为“/Users/Test/Desktop//Myfolder/Hi.txt”?
答案 0 :(得分:5)
这里你去了
set aFile to (the POSIX path of (path to desktop)) & "Myfolder/Hi.txt"
答案 1 :(得分:1)
使用Concatenation operator加入字符串:
set the folderPath to "/Users/Test/Desktop/"
set the filePath to "/Myfolder/Hi.txt"
set the fullPath to folderPath & filePath