I need help on dismissing a UIAlertView programmatically. Currently I have this

UIAlertView *alert1 = [[UIAlertView alloc]initWithTitle:@"title" message:@"message" delegate:nil cancelButtonTitle:nil otherButtonTitles:nil];

then later on I call this

[alert1 dismissWithClickedButtonIndex:0 animated:NO];

but nothing happens.

Edit
Report