I created a custom navigation controller,
I want to add a date on the left, a back button on the right, and a title next to the back button.
I tried to add one shortcut, but it does not work. Please show me the way
UINavigationBar *naviBarObj = [[UINavigationBar alloc] initWithFrame:CGRectMake(0, 0, 1024, 66)]; UILabel *navLabel = [[UILabel alloc] initWithFrame:CGRectMake(20,8,280,30)]; navLabel.text = @"My Text"; [self.navigationController.navigationBar addSubview:navLabel]; [self.view addSubview:naviBarObj];
source share