How can I get these little views below to appear in the iOS SDK?

I am talking about small windows with buttons that go from the bottom when you need to confirm some action. For example, if you want to delete a photo from an album and click the trash can icon, a small image will move below and ask if you want to delete the photo or cancel

How do I get these submissions?

+5
source share
2 answers

Use the UIActionSheet.

UIActionSheet *actionSheet = [[UIActionSheet alloc] initWithTitle:@"Some Action"
                                           delegate:self 
                                  cancelButtonTitle:@"Cancel"
                             destructiveButtonTitle:@"OK"
                                  otherButtonTitles: nil];

actionSheet.actionSheetStyle = UIActionSheetStyleDefault;
[actionSheet showInView:self.view];
[actionSheet release];
+9
source

All Articles