Thorsten
Thorsten

Reputation: 13181

How to set backgroundColor for navigationItem?

I'm trying to format the navigationItem at the top of my main tableView. I've managed to set the title that is displayed by this code

[[self navigationItem] setTitle:@"MyTitle"];

But I haven't found a way to access the backgroundColor. I'd like to something like this

[[self navigationItem] setBackgroundColor:[UIColor colorRed]];

But this doesn't work. Any other ideas?

Upvotes: 2

Views: 6616

Answers (1)

Related Questions