Reputation: 53
Like using UIAlertView on iOS. There should be a similar solution for creating a pop-up message on macOS. Tried to search but could not find anything useful.
Upvotes: 3
Views: 2018
Reputation: 130183
The class you're looking for is NSAlert
. Information on this class can be found in its class reference here. And here is an example of its usage:
NSAlert *alert = [[NSAlert alloc] init];
[alert setMessageText:@"Some awesome message text"];
[alert addButtonWithTitle:@"OK"];
[alert runModal];
Upvotes: 2