views:

15

answers:

1

I added UIWindow and its toolbar like:

self.window = [[[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]] autorelease];
NSArray * arr = [NSArray arrayWithObjects:@"test1", @"test2", nil];
[[self.window rootViewController] setToolbarItems:arr animated:NO];

No toolbar showing up.

Is it doable? Thanks.

A: 

You should add your viewController (with a toolbar) to the window after the window's init.

MathieuF