1

I am setting a tag for my navigationBar using:

self.navigationController.navigationBar.tag = 1;

When you select a cell and the child UITableView loads, I set:

self.navigationController.navigationBar.tag = 2;

But when I hit the 'back' button and the Parent UITableView appears again, the .tag is still set to 2.

I have tried setting tag=1 in the Parent's viewDidLoad, viewWillAppear, viewDidAppear and in the Child's viewWillDisappear - any help would be greatly appreciated.

4

1 回答 1

0

As a rule of thumb, only use .tag properties on non-system UIView classes. You might be better off mapping these navbars in an NSMutableArray.

于 2010-02-24T17:32:01.970 回答