此TabBar结合了picker View

 

在代理类中加

- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
self.window = [[[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]] autorelease];
// Override point for customization after application launch.
UIViewController *datePickerView = [[[DatePickerViewController alloc] initWithNibName:@"DatePickerViewController" bundle:nil] autorelease];

UIViewController *singleComponentPickerView = [[[SingleComponentPickerViewController alloc] initWithNibName:@"SingleComponentPickerViewController" bundle:nil] autorelease];

UIViewController *doubleComponent = [[[DoubleComponentPickerViewController alloc]initWithNibName:@"DoubleComponentPickerViewController" bundle:nil] autorelease];

UIViewController *dependentComponent = [[[DependentComponentPickerViewController alloc]initWithNibName:@"DependentComponentPickerViewController" bundle:nil] autorelease];

UIViewController *customPicker = [[[CustomPickerViewController alloc]initWithNibName:@"CustomPickerViewController" bundle:nil] autorelease];





self.tabBarController = [[[UITabBarController alloc] init] autorelease];
self.tabBarController.viewControllers = [NSArray arrayWithObjects:datePickerView, singleComponentPickerView , doubleComponent, dependentComponent, customPicker, nil];

self.window.rootViewController = self.tabBarController;
[self.window makeKeyAndVisible];
return YES;
}