Button to Recognize Selected Path
Trying to have a button confirm the index selected in a tableview with a
special class. This is how I would NSLog the result of the selected index.
- (void)selector:(IZValueSelectorView *)valueSelector
didSelectRowAtIndex:(NSInteger)index {
NSLog(@"Selected index %d",index);
}
but I'm not sure how I'd confirm that with a button since the button uses
an IBAction.
I want an alert to pop up once they click the button. This is what I have
so far, but I get an error since it doesn't recognize what index means:
- (IBAction)submit:(id)sender {
UIAlertView *submit = [[UIAlertView alloc]
initWithTitle:@"Submit"
message:(@"Are you sure you want to submit %i", index)
delegate:self
cancelButtonTitle:@"No"
otherButtonTitles:nil];
[submit show];
}
No comments:
Post a Comment