Player
Documentation
AppleScript
User's Guide
Chapter 5, Verbs
One Verb Per Page
set: dialog folder (new in 1.1) -- for standard file dialog (not Navigation Services)
Syntax
set dialog folder to path
Parameters
path -- path name to a folder
Result
true
Examples
set dialog folder to alias("Macintosh HD:Cool Stuff:Benchmarks")
do menu menu item "Save As" of menu "File"
Notes
- This verb works only with "classic" standard file dialogs not with the new "Navigation Services" dialogs.
- Call this verb before performing an action that displays a standard file or folder dialog; it sets the folder that the dialog will show when displayed.
- The verb can also be called while the dialog is open, though that's less efficient.
- The verb requires an alias, it will not accept a Finder reference. To convert a variable that holds a Finder reference:
tell application "Finder"
set theVariable to theVariable as string -- or: as alias
end tell- Instead of using Player (and this new verb) to open a file by controlling the Open file dialog, you can usually tell the Finder to open the file. This verb is still useful for the Save dialog or Import dialogs.
- If you do need to point to a file, just use the type verb with the name of the file (after the dialog is open):
set dialog folder to alias("Macintosh HD:Here")
do menu menu item "Import" of menu "File"
type "results doc"
click button "Import"- This verb replaces PlayerLib's locateFile and locateFolder which are now obsolete.
set target window
Copyright 1993-99, PreFab Software, Inc. All Rights Reserved.
This site built and maintained using Stage Three, a set of custom Frontier scripts.