動的 IP を .txt ファイルに自動的に書き込むスクリプトを使用していますが、終了ボタンをクリックしてもダイアログを閉じることができないという問題があります。
set yn to (display dialog "Your ip has been written to the server, the application will re-run in 10 minutes if you DO NOT close this window." buttons {"Quit", "Run again"} giving up after 600)
if yn is equal to "Quit" then
quit
end if