Posted By

steve918 on 02/06/09


Tagged

objc alert iphone pdxiphone


Versions (?)

Who likes this?

12 people have marked this snippet as a favorite

windmarble
cgrainger
umang_nine
hERB
avanadra
peetj
leoavesani
gerhardsletten
FumarMata
epaga
AndreyZarembo
cnathan


Simple alert box on iPhone


 / Published in: Objective C
 

Display simple alert box

  1. UIAlertView *someError = [[UIAlertView alloc] initWithTitle: @"Network error" message: @"Error sending your info to the server" delegate: self cancelButtonTitle: @"Ok" otherButtonTitles: nil];
  2.  
  3. [someError show];
  4. [someError release];

Report this snippet  

Comments

RSS Icon Subscribe to comments
Posted By: gfazioli on June 4, 2009

If you use a delegate:self you can insert relative event in your viewController:

-(void)alertView:(UIAlertView *)alertView clickedButtonAtIndex:(NSInteger)buttonIndex { // todo }

You need to login to post a comment.