I'm new to IOS, so be kind to answer to my question :). I have a dynamic UITable populated with UIButtons. Two buttons for each row. Buttons are presented as pictures. Before passing to next view I need to keep data of selected button. Buttons have tags (attached when beeing populated in UITableView). My problem is that for normal functioning of programm is needed call of -(IBAction)firstButtonTag:(id)sender; or -(IBAction)secondButtonTag:(id)sender; (for storage of Tag in singleton class) and than only call of prepareForSegue method, but currently the logic is working only for buttons in first column, for buttons in second is called prepareForSegue (without call of -(IBAction)secondButtonTag:(id)sender;)
Thanks in advance :)
It's hard to understand what you need, but to me it looks like you just need to do some calls before doing a segue on button press.
Just perform segue programmaticaly in button action handler:
-(IBAction)buttonPressed:(id)sender
{
... // do your stuff here
[self performSegueWithIdentifier:@"segueId" sender:nil];
}
You also need to remove triggered segue from buttons and add manual segue and set its identifier.