This article was previously published under Q113891
Microsoft Excel for Mac and later versions support AppleScript in the scriptable capacity. With this feature, you can control Excel for Mac from other programs or scripts.
AppleScript is an English-like language that is used to write script files that can control the actions of the computer and the programs that run on it. To use the program-specific capabilities of Excel for Mac with AppleScript, open and examine the AppleScript dictionary that is supplied with Excel for Mac.
To use the Script Editor open the dictionary in Excel for Mac,follow these steps:
Start the Script Editor. To do this, follow these steps:
Open your hard disk.
Open the Applications folder.
Open the AppleScript folder. For the Apple OS versions earlier than OSX, open the Apple Extras folder, and then open the AppleScript folder.
Double-click Script Editor.
On the File Menu, click Open Dictionary.
In the Open Dictionary dialog box, select Microsoft Excel (Application) in the Name list, and then click Open.
In the window that appears, you can select an object or a class toview its description. You can also click the bold suite names to view anwhole suite at one time. You can use the descriptions in this window tocreate scripts in the Script Editor to control Excel for Mac.
The versions of Excel for Mac listed at the beginning of this article support a very large number of events. For a complete list, follow the instructions in this article to open Excel for Mac in the AppleScript Script Editor.
If you are not familiar with AppleScript or you do not know how to use the Macintosh Script Editor to browse scripting dictionaries and to create and debug scripts, study at least one of the following resources:
Danny Goodman's AppleScript Handbook by Danny Goodman. A reprint of the classic introduction to AppleScript; it is published on demand. Contains information about scripting Word and Excel in particular but is useful generally.
AppleScript for the Internet by Ethan Wilde. An excellent introduction to scripting Internet applications on the Macintosh. It contains chapters with information about scripting Microsoft Outlook Express and Internet Explorer, and about scripting basic Apple Internet software such as Open Transport. It also contains a complete introduction to the AppleScript language itself. Highly recommended, even if you are not scripting Microsoft Outlook Express or Microsoft Internet Explorer.
AppleScript for Dummies by Tom Trinko. A solid tutorial about AppleScript for the novice; available at bookstores.
The Apple Computer AppleScript Web site. This Web site has links to many other sources of information about AppleScript and scripting the Macintosh, including overviews, tutorials, and AppleScript-related utility software. To use this these links, visit the following Apple Web site:
Microsoft provides third-party contact information to help you find technical support. This contact information may change without notice. Microsoft does not guarantee the accuracy of this third-party contact information.