iPhone SDK Alert Box

Just call alert box.

- (IBAction)buttonPressed:(id)sender {

NSString *favouriteMac = [sender titleForState:UIControlStateNormal];

NSString *alertViewText = [[NSString alloc] initWithFormat:@”Simple”,favouriteMac];

UIAlertView *alert=[[UIAlertView alloc] initWithTitle:@”Favourite”

message:alertViewText

delegate:nil

cancelButtonTitle:@”No”

otherButtonTitles:@”YES”,nil];

[alert show];

[alert release];

}

One thought on “iPhone SDK Alert Box

  1. Pingback: Meet the new language | Saturngod

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>