
The new command is in the form AppleScriptTask("script file name.scpt", "handler name", "handler argument"), for example: Dim FolderPath as StringĪppleScriptTask("MyScript.Place the script in your user's ~/Library/Application Scripts/ folder, where is the bundle identifier of the application using the script.Tell application "Finder" to open folder folderPath


Untested examples: The older (deprecated) style: That program is free to join and open to everyone. Note that the open shell utility is normally used to open files and applications. Where theFolder is an alias, file, or POSIX file object, for example from: set theFolder to (choose folder) You can always run a macro by clicking the Macros command on the Developer tab on the ribbon. Macros are recorded in the Visual Basic for Applications programming language. In the case of the Finder (which runs at all times), It would be: tell application "Finder" to open theFolder A macro is an action or a set of actions that you can use to automate tasks.

AppleScript does these kinds of things by telling a particular application to perform one or more of the commands exposed in the scripting dictionary (if any) provided by the application developer.
