Displays the panel and begins a modal event loop that is terminated when the user clicks either OK or Cancel.
- macOS 10.0–10.6Deprecated
The directory whose files the panel displays. When
nil, the directory is the same directory used in the previous invocation of the panel; this is probably the best choice for most situations.
Specifies a particular file in
absolutethat is selected when the Open panel is presented to the user. When
nil, no file is initially selected.
An array of file extensions and/or HFS file types. Specifies the files the panel allows the user to select.
nilmakes all files in
absoluteselectable by the user. An array of types passed in here will override one set using
The button clicked to dismiss the dialog:
NSOKButton for the OK button and
NSCancel for the Cancel button.