Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

applescript garbled

I have several Applescripts that wrote recently that work perfectly but when I open them in Script Editor they look garbled.


Here is an example snippet:

--find the line that the thumbs tag is on

«event R*chFind» thumbsLine with «class SelM» given «class FnIn»:text 1 of «class TxtW» 1, «class Opts»:{«class SMod»:text, «class STop»:true, «class Rvrs»:false, «class Case»:false, «class Wrds»:false, «class ExSl»:false}

copy the «class SLin» of «class pusl» of window 1 to thumbsLineCount


This is what it's supposed to look like:

--find the line that the thumbs tag is on

find thumbsLine searching in text 1 of text window 1 options {search mode:text, starting at top:true, backwards:false, case sensitive:false, match words:false, extend selection:false} with selecting match

copy the startLine of selection of window 1 to thumbsLineCount


Sometimes Script Editor will open them fine and sometimes they're all garbled. I'm on Yosemite with all the latest updates.


Does anyone know what's going on?


Thanks

OS X Yosemite (10.10.2)

Posted on Mar 1, 2015 7:29 PM

Reply
Question marked as Best reply

Posted on Mar 2, 2015 4:54 PM

Those are just the raw Apple Event codes - the Script Editor looks up the event codes in an application's scripting dictionary and replaces them with the specified term. You will normally see this when a script uses terminology for an application that is not installed, or for a version with different scripting terms.

2 replies
Question marked as Best reply

Mar 2, 2015 4:54 PM in response to reallyrandy

Those are just the raw Apple Event codes - the Script Editor looks up the event codes in an application's scripting dictionary and replaces them with the specified term. You will normally see this when a script uses terminology for an application that is not installed, or for a version with different scripting terms.

applescript garbled

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple ID.