I have a library handler that read a text file generated by another script. It stores an Applescript record in the test file for information passing between scripts. It reads the file in with the line:
set existingRecord to read POSIX file recordLocation as record
Which has been working fine for years…
then today I add a new, unrelated handler that contains some ASObjC code, so at the top of the library, I add:
use framework "Foundation"
Now when the handler gets to the line:
set existingRecord to read POSIX file recordLocation as record
It errors:
Apparently there’s some terminology conflict there, where it’s attempting to evaluate my Applescript code as ASObjC code, and it’s failing? But I don’t understand why. Can someone please explain why it’s failing, and also how I fix it?
Thanks.