I\'m trying to discover what the UIButton title is for which UIButton was pressed in the following code.
on viewDidLoad the button title is outputted to the console usin
You should have the function somewhere...
- (void)buttonPressed:(id)sender
Just put this inside it...
- (void)buttonPressed:(id)sender
{
UIButton *someButton = (UIButton*)sender;
NSLog(@"The button title is %@ ", [someButton titleForState:UIControlStateNormal]);
//You should also be able to use...
//NSLog(@"The button title is %@ ", someButton.titleLabel.text);
}