More than 5 tabs in tab bar controller
Hi,
I'm totally at a lost trying to get 6 tabs connected to my tab bar controller, which was created using the tab bar controller template. Everything thing works fine with 5 view controllers. When I add a 6th view controller I get the "More" tab in the 5th position, which when touched opens up a table view showing 2 more tabs for the user to choose from. Touching either row in this table view causes the app to crash. The error reads:
2011-06-26 20:37:25.276 TMO[2761:207] will dissapear
2011-06-26 20:37:27.157 TMO[2761:207] -[UIMoreListController __touchesEnded:withEvent:]: unrecognized selector sent to instance 0x4c3c010
2011-06-26 20:37:27.159 TMO[2761:207] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[UIMoreListController __touchesEnded:withEvent:]: unrecognized selector sent to instance 0x4c3c010'
*** Call stack at first throw:
(
0 CoreFoundation 0x014285a9 __exceptionPreprocess + 185
1 libobjc.A.dylib 0x0157c313 objc_exception_throw + 44
2 CoreFoundation 0x0142a0bb -[NSObject(NSObject) doesNotRecognizeSelector:] + 187
3 CoreFoundation 0x01399966 ___forwarding___ + 966
4 CoreFoundation 0x01399522 _CF_forwarding_prep_0 + 50
5 UIKit 0x003aa0f4 forwardMethod2 + 92
6 UIKit 0x003aa0f4 forwardMethod2 + 92
7 UIKit 0x003aa0f4 forwardMethod2 + 92
8 TMO 0x00006df6 -[UIView(__TapHook) __touchesEnded:withEvent:] + 51
9 UIKit 0x0056f4de _UIGestureRecognizerSortAndSendDelayedTouches + 3609
10 UIKit 0x0056fc53 _UIGestureRecognizerUpdateObserver + 927
11 CoreFoundation 0x0140989b __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 27
12 CoreFoundation 0x0139e6e7 __CFRunLoopDoObservers + 295
13 CoreFoundation 0x013671d7 __CFRunLoopRun + 1575
14 CoreFoundation 0x01366840 CFRunLoopRunSpecific + 208
15 CoreFoundation 0x01366761 CFRunLoopRunInMode + 97
16 GraphicsServices 0x019971c4 GSEventRunModal + 217
17 GraphicsServices 0x01997289 GSEventRun + 115
18 UIKit 0x002eac93 UIApplicationMain + 1160
19 TMO 0x000024fc main + 102
20 TMO 0x0000248d start + 53
)
terminate called after throwing an instance of 'NSException'
Any help or direction will not go unappreciated 🙂 I've scoured the web and this forum for an answer I can understand. I did get bits of code and explanations regarding using:
UIViewController *moreViewController = tabBarController.moreNavigationController.topViewController;
UITableView *moreTableView = (UITableView*)moreViewController.view;
But, it's wasn't enough me to understand how to piece it all together.
Thanks,
Amy
iPhone 3G, iOS 3.1.2