Thursday, October 6, 2022

#1 2005-10-13 02:26:07 pm

From:: Malasaña, Madrid
Registered: 2002-11-20
Posts: 2014

How can I manipulate non-scriptable applications? (pre OS X)

It's easy to launch a non-scriptable application but difficult to easily do anything too productive with it. Consider the following line:


tell application "SimpleText" to activate

This will launch "Simple Text" but having it do anything afterward would require scripting additions. A free Scripting Addition called S�¤ndi's Additions allows text to be typed, so we could do something like:


tell application "SimpleText"
   TypeText "Hello!"
end tell

To choose from menus, access dialog boxes, and do more would require other additions, or an all-in-one extension called PreFab Player.

In general, non-scriptable applications are cumbersome to deal with and more often than not a scriptable equivalent can be found; in this case the $15 shareware text editor Tex-Edit Plus is highly scriptable and offers other features Simple Text can only dream about!

Filed under: SimpleText



Board footer

Powered by FluxBB

RSS (new topics) RSS (active topics)