AppleScript error message: can't make... into type string

Discussion in 'Mac Programming' started by MeLee1991, May 10, 2010.

  1. MeLee1991 macrumors newbie

    Joined:
    May 10, 2010
    #1
    What am i doing wrong?
    I get this error message: can't make... into type string

    I would like to delimit text from some text file (and later extract data from specific position):

    set the_file to alias "Macbook:new.txt"
    open for access the_file

    try
    repeat
    set the_string to read the_file
    set text item delimiters to "--------"
    set delimited_text to text items of the_string
    display dialog delimited_text
    end repeat
    on error number -39
    close access the_file
    end try


    Please help.
    Ty.
     
  2. kainjow Moderator emeritus

    kainjow

    Joined:
    Jun 15, 2000

Share This Page