Como alterar o título do UIbutton depois que um botão do UI é pressionado?
Estou tendo problemas para alterar o título do UIButton btn2 depois que btn1 é pressionado. Quando eu uso_definition settitle:@"Show Word" forState: UIControlStateNormal
altera o btn1 original.
Aqui está o código para sua análise,
- (IBAction)mynextPressed:(UIButton *)sender {
//Display the string in the label field
[self.WordDisplay setText:vocabulary];
//reset center button with "show word"
[_definitionPressed setTitle:@"Show Word" forState:UIControlStateNormal];
NSLog(@"displaying word: %@", _definitionPressed.titleLabel);
}