Add a selection view to the action sheet. First of all, make sure that youre view controller impliments UIPickerViewDelegate and UIActionSheetDelegate.
Then add this method and call it when you want to show your selector.
- (void)showPicker { UIActionSheet *menu = [[UIActionSheet alloc] initWithTitle:@"Pick Value" delegate:self cancelButtonTitle:@"Done" destructiveButtonTitle:nil otherButtonTitles:nil]; UIPickerView *pickerView = [[UIPickerView alloc] initWithFrame:CGRectMake(0,180,0,0)]; pickerView.delegate = self; pickerView.dataSource = self; pickerView.showsSelectionIndicator = YES; [menu addSubview:pickerView]; [menu showInView:self.view.superview];
source share