TextEdit Icon

Automating TextEdit tasks with AppleScript

TextEdit includes AppleScript terms that let you automate tasks using scripts. You can use scripts to add text, copy information, set styles, or export information from a TextEdit document for use by another application.

To see the TextEdit terms and write scripts, you can use AppleScript Editor, included with Mac OS X.

To view the AppleScript terms you can use for TextEdit:

  1. Open AppleScript Editor, in the Utilities folder in the Applications folder.

  2. Choose File > Open Dictionary.

  3. Select TextEdit and click Choose.

To learn more about AppleScript and how to use scripting terms, choose Help > AppleScript Help while you’re working in AppleScript Editor, or visit the AppleScript website.


Open

AppleScript website

Open the AppleScript dictionary for TextEdit