Set background color for UINavigationBar

前端 未结 9 605
滥情空心
滥情空心 2020-12-18 07:07

I want to develop UINavigationBar and also set background color for that. I have created the UINavigationBar but I have problem with setting backgr

9条回答
  •  一整个雨季
    2020-12-18 07:56

    [self.navigationController.navigationBar setBackgroundColor:[UIColor redColor]];
    

    Try like this. I think it will be helpful to you.

    Edit: updated the code to actually compile.

提交回复
热议问题