everyone!
So basically, I am trying to create a simple toggle out of my UIButton. With the code below, I am able to click the button, but only for a brief moment do I see @"Expense" as the title. It is probably a VERY simple mistake. Any help is appreciated!
- (IBAction)typeChanger {
if ([typeButton.titleLabel.text isEqual:@"Income"]) {
typeButton.titleLabel.text = @"Expense";
}else if ([typeButton.titleLabel.text isEqual:@"Expense"]) {
typeButton.titleLabel.text = @"Income";
}
}
Thanks in advance!