Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

crobbulan

macrumors newbie
Original poster
Hi there,

I have been using simple AppleScripts to send code to a CAD application through QuickKeys. Unfortunately, my new setup has broken this system.

Basically, the script sends a few lines of code to the application using a built-in "DoScript" call. For example:

Code:
tell application "VectorWorks 12.5.3"
DoScript
"Procedure PrefToggle;
Begin
SetPref(10,NOT(GetPref(10)));
End;

Run(PrefToggle);"
end tell
This worked great under Tiger but fails in Snow Leopard. It's my understanding that the problem is that 10.6 now sends text from scripts in Unicode, which the older version of VectorWorks (12.5.3) does not interpret. What I think I need to do is send the text from a plain text file. That file could be stored on my computer in any location (preferably Macintosh HD/Library/Application Support/)

I'm new to scripting and am having trouble doing this. Any help would be great.

The Crobbulan
 
This link may help - Link

It has some information about reading files as ascii specifically the Macintosh Encoding which may help in what you are trying to do.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.