(Beginner) NSAlert?
  #1 (permalink)  
Unread 02-16-2010, 08:25 PM
rodrigofms rodrigofms is offline
Junior Member
 
Join Date: Feb 2010
Posts: 1
Question (Beginner) NSAlert?

Hello guys
I'm trying to show a NSAlert when the user click an button... but nothing happens. Here's the implementation code:

Code:
#import "untitled.h"


@implementation untitled
-(IBAction)showAlert:(id)sender
{
	NSAlert *myAlert = [NSAlert alertWithMessageText:(@"Message") defaultButton:(@"OK") alternateButton:nil otherButton:nil informativeTextWithFormat:nil];
	[myAlert beginSheetModalForWindow:mainWindow modalDelegate:self didEndSelector:nil contextInfo:nil];
}
@end
When I run the app and click on the button, this appears on the console:
Code:
2010-02-16 19:24:25.022 NSAlert[83640:a0f] *** -[NSPlaceholderString initWithFormat:locale:arguments:]: nil argument
What do you think?
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT. The time now is 11:10 PM.


vBulletin skin developed by: eXtremepixels
Powered by vBulletin® Version 3.8.2
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.0



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28