-1
我想製作一個程序,需要人選擇一個文件,並試圖確認它。當我嘗試在if塊中添加重複項時,遇到了一個問題。有沒有任何解決方法,因爲這是令人難以置信的挫折。提前致謝! :)在if塊中重複?
display dialog "Select the program"
tell application "Finder"
set filePath to POSIX path of (choose file)
end tell
display dialog "Are you sure this is the program that you have selected?"
buttons {"Yes", "No"}
if the button returned is "No" then
end repeat
else
感謝您的幫助。我現在的代碼都在工作,並且完全理解我做錯了什麼。感謝您指出! :) – user7439349
不客氣。來自http://stackoverflow.com/help/someone-answers:「要將答案標記爲已接受,請單擊答案旁邊的複選標記以將其從灰色變爲填充。」 – CRGreen