Tuesday, April 3, 2018 [Tweets] [Favorites]

Adding AppleScriptObjC to Existing Scripts

Shane Stanley:

The script runs fine (assuming you have a file called Test.txt on your Desktop), until you uncomment the use framework line, after which you get the error: “Can’t make current application into type file.” That’s not very helpful.

The solution is to change the code so you build file references using coercions.

In other words, as alias instead of using a string that represents a path. I usually use POSIX file "path", and that also works.

Comments

Stay up-to-date by subscribing to the Comments RSS Feed for this post.

Leave a Comment