icant
icant

Reputation: 888

Change UIViewController title from UITableViewCell

I have a custom UITableViewCell with a UITextField and a method that is being called when the user changes the text in the textField. How do I change the title of the ViewController when the text in the textField is changed?

Upvotes: 1

Views: 545

Answers (1)

Julian
Julian

Reputation: 1603

You have to create an outlet for your textField and then you can just set your ViewControllers title property to be your textField's text. Something like the following should do the trick:

[self.delegate.title=textField.text];

Upvotes: 2

Related Questions