Runs the alert as an app-modal dialog and returns the constant that identifies the button clicked.
- macOS 10.3+
A response to the alert. See this method’s “Special Considerations” section for details.
You can create the alert either through the standard allocation and initialization procedure or, if necessary in your app, by using the deprecated compatibility method
If you use
alert to create an alert, the
NSAlert constants identify the button used to dismiss the alert. Otherwise, the constants used are the ones described in