views:

57

answers:

1

While declaring a simple UIAlertView, with the following code, I get the above mentionned error on that line:

UIAlertView * alerteken =  [[UIAlertView alloc] initWithTitle:@"Email" message:@"Please enter the @mailinator.com email address you want to read:" delegate:self cancelButtonTitle:@"Cancel" otherButtonTitles:@"Ok"];

What am I doing wrong?

+5  A: 

You need to provide a list of button titles terminated with a "nil" at the end:

otherButtonTitles:@"Ok",nil
Estarriol
Thanks, this solved my problem :)
Yvan JANSSENS