【发布时间】:2013-05-31 00:25:45
【问题描述】:
我有一个写在文本文件中的数字。是否可以在文本文件中添加另一个号码,然后用新号码替换旧号码?这是我的代码:
set theFile to POSIX path of "Users:Tyler:Documents:File.txt"
open for access theFile
set theFileContents to read theFile
set theNewFile to run script theFileContents + 1
tell application "TextEdit"
set eof of theFileContents to 0
write theNewFile to theFileContents
【问题讨论】:
标签: variables text numbers applescript add