TOPIC This article comprises the Read Me for AppleScrip Update 1.4.3 and software download links. DISCUSSION
About AppleScript UpdateThis document describes the specific fixes in this AppleScript Update. We have also included the content from the original Read Me that describes the AppleScript software, tells you where to find information on using AppleScript, and lists the new features of AppleScript that originally shipped with Mac OS 9. What is fixed in this AppleScript Update? There were three issues fixed with this AppleScript Update: 1. The performance of the AppleScript Script Editor could be adversely affected by an interaction with Carbon Lib 1.02. 2. The computer would stop responding when attempting to compile scripts simultaneously. 3. Inability of Standard Additions "mount volume" command to mount NT, OS X or other non-AppleShare volumes. The following information is from the original AppleScript Read Me and it may provide helpful information to those of you who are just starting to use AppleScript. What is AppleScript?AppleScript is software that allows you to automate tasks on your computer. For example, you can write an AppleScript to automatically empty the Trash, or to add an alias to the Apple menu. Using AppleScript's English-like commands, you describe the task, then save it as a "script" file. For more information, see AppleScript Help in the Finder's Help menu. How AppleScript worksWhen you tell your computer to do a task by choosing a menu command, for example, the operating system and applications on your computer talk to each other using a messaging tool called Apple events. Apple events transfer information, commands, and requests between applications, networks, and the Mac OS-much like we use phone calls, pagers, or e-mail to communicate with each other. When you send an AppleScript message, the operating system converts the script's instructions into Apple events messages, then sends the events to the indicated applications where the instructions are executed. How to use AppleScriptTo learn more about AppleScript and how to use it, choose Help Center from the Finder's Help menu, then click on AppleScript Help. AppleScript Help contains an overview of new AppleScript features, as well as background information and instructions on how to use AppleScript. Additionally, the Mac OS CD includes sample scripts and information about AppleScript in a folder named CD Extras. You can also find detailed AppleScript information, tutorials, scripts, and links to other resources on the AppleScript Web site: http://www.apple.com/applescript/ About AppleScriptThe version of AppleScript included with this Mac OS corrects some issues with the previous versions of AppleScript, and also has some added enhancements. For more information on many of these features, see AppleScript Help. IMPORTANT : The version of AppleScript included with this version of the Mac OS is designed for use only with this OS version. It is not designed or qualified for use with earlier Mac OS releases (8.6 and earlier). NOTE : The former English dialect file is now built into the AppleScript extension. AppleScript Help also details all the changes in this version of AppleScript from the previous version shipped with Mac OS 8.6. Some of the new features in this release include: Support for IP addressing for Program LinkingYou can now link to remote applications using TCP/IP addressing as well as the traditional AppleTalk addressing. The "machine" object can now accept a URL instead of an AppleTalk machine name. When used in a "Tell" block, this enables you to deliver AppleEvents to remote applications via TCP/IP protocol. Previously, remote applications could only be specified using an AppleTalk address consisting of machine name plus an optional zone name, as follows: tell application "Finder" of machine "Lab Mac" [of zone "4th Floor"] Now you can specify the TCP/IP address of the machine instead of the AppleTalk name and zone: tell application "Finder" of machine "eppc://labmac.mycompany.com" Note: The URL for a computer has nothing to do with its AppleTalk name, and there is no support for "browsing" a TCP/IP network to look for remote computers. You must know the IP address (for example, 127.200.126.44) or the computer and domain names (for example, labmac.mycompany.com) of the target computer. These can be found in that computer's Web Sharing control panel (turn on Web Sharing and look in the Web Identity panel). Support for "Using" ClauseA new block structure has been included to allow scripts to be compiled without connecting to the actual target application. This is especially useful if the application is unknown at compilation time (for example, the application goes by different names on different computers) or it's awkward to connect to it during script development (for remote applications over TCP/IP, for example). The syntax of the "using terms from" block is as follows: using terms from application-object[of computer-object[of zone-object]] statement(s) ... end using terms from Statements inside this block are compiled as if enclosed in a "Tell" block for that application, but their targeting is unaffected; if inside another "Tell" block, that "Tell" block's target is used; if not, the current application is targeted. Blocks for "Tell" and "using terms from" can be nested inside each other. This is a more clear substitute for the commonly-used "double tell block" to target unknown applications: set the_reply to display dialog "Enter name or URL of remote computer:" default answer "" set m to computer (text returned of the_reply) tell application "Finder" of m -- Target a remote computer using terms from application "Finder" -- but use terminology from local computer's Finder set the_list to (name of every process) -- "process" is a Finder-specific term end using terms from end tell set the_application to first item of (choose from list the_list with prompt "Choose an application:") tell application the_application of m set the_version to version end tell display dialog "The version of that application is " & (the_version as string) Improvements in searching for applicationsWhen a script with a "Tell application" statement is compiled, AppleScript needs to find the application with the name given. If the application is running, or is a standard double-clickable application, this almost always succeeds; but for certain kinds of applications (system extensions, control panels, etc.) the search sometimes fails and the "Where is application" dialog box is presented. This version of AppleScript automatically searches the System Folder and its enclosed folders for such applications by name, increasing the chances that the application you name will be found without the dialog box. About the AppleScript CD Extras folderIn the CD Extras folder on the Mac OS CD ROM, there is an AppleScript folder containing the following items: Third-party AppleScript productsAlthough AppleScript comes with Script Editor, there are a number of third-party tools that can also help you develop AppleScripts: |
Document Information | |
Product Area: | Apple Software |
Category: | AppleScript |
Sub Category: | General Topics |
Keywords: | kaswu, kbdload |
Copyright © 2000 Apple Computer, Inc. All rights reserved.