Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

Sergio10

macrumors regular
Original poster
Oct 3, 2007
137
0
Hi guys,

Need to change buttons on toolbar(UIToolBar) with animation.
I use next code:

PHP:
UIBarButtonItem* item = [[UIBarButtonItem alloc] initWithTitle:@"test" style:UIBarButtonItemStylePlain target:nil action:nil];
NSArray* items = [NSArray arrayWithObject:item];
[_bottomToolBar setItems:items animated:YES];

As result nothing appear and without animation as well.
How to solve the problem?
 
The setItems:animated: method is designed to be used when you use the toolbar that UINavigationController gives you for free. It will not help you set items for an arbitrary toolbar.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.