hey, i got some problems, if anyones abel to help.
first of all, i want a apple script to read a text file, and set a variable to a specific line of text, like a number, such as line 20. but, i want the line of text to read to be a variable. for example, if “linetoread” was set to 7, it would read line 7 of the text file. is this possible?
also, i would like linetoread to be set to linetoread +1, so that it would go up one every time it is repeated, checking every line.
can anyone help?
get started with this:
set theFile to "path:to:some file"
set ff to open for access theFile with write permission
set thetext to (read ff)
set allparas to every paragraph of thetext
how do i “close the file”
is it just close thisFile?
also, is it possible to have a variable set in apple script in a shell script? and can shell scripts write to these variables?
also, how can i log in with an apple script, i see no way to put a password in.