title: UITabBarContrtoller achieve from a different class in iPhone
body: <p>I have the following problem:
  There is a class that includes five tabs in the following way:</p>
  
  <p>mainMenuClient.h</p>
  
  <pre><code>#import &lt;UIKit/UIKit.h&gt;
  
  @interface MainMenuClient : UIViewController {
  UITabBarController *tabBarController;
  }
  @property (nonatomic, retain) UITabBarController *tabBarController;
  
  @end
  </code></pre>
  
  <p>mainMenuClient.m</p>
  
  <pre><code>-(void)viewDidLoad {
  
  UIView *contentView = [[UIView alloc] initWithFrame:[[UIScreen mainScreen] applicationFrame]];
  contentView.backgroundColor = [UIColor blackColor];
  self.view = contentView;
  [contentView release];
  
  ContactListTab *contactTab = [[ContactListTab alloc] init];
  ChatTab *chat = [[ChatTab alloc]init];
  DialerTab *dialer = [[DialerTab alloc]init];
  MenuTab *menu = [[MenuTab alloc]init];
  TesztingFile *teszting = [[TesztingFile alloc]init];
  contactTab.title = @"Contact List";
  chat.title = @"Chat";
  dialer.title = @"Dialer";
  menu.title = @"Menu";
  teszting.title = @"TesztTab";
  
  contactTab.tabBarItem.image = [UIImage imageNamed:@"Contacts_icon.png"];
  chat.tabBarItem.image = [UIImage imageNamed:@"Chat_icon.png"];
  dialer.tabBarItem.image = [UIImage imageNamed:@"Dialer_icon.png"];
  menu.tabBarItem.image = [UIImage imageNamed:@"Menu_icon.png"];
  teszting.tabBarItem.image = [UIImage imageNamed:@"Contacts_icon.png"];
  chat.tabBarItem.badgeValue = @"99";
  
  tabBarController = [[UITabBarController alloc]init];
  tabBarController.view.frame = CGRectMake(0, 0, 320, 460);
  
  [tabBarController setViewControllers:[NSArray arrayWithObjects:contactTab, chat, dialer, menu, teszting, nil]];
  
  [contactTab release];
  [chat release];
  [dialer release];
  [menu release];
  [teszting release];
  
  [self.view addSubview:tabBarController.view];
  
  [super viewDidLoad];
  }
  </code></pre>
  
  <p>In the contactTab class there are a UITableViewController.</p>
  
  <p>contactTab.h</p>
  
  <pre><code>- (void)updateCellData;
  - (void)configureCell:(UITableViewCell *)cell forIndexPath:(NSIndexPath *)indexPath;
  </code></pre>
  
  <p>There is a third class, which I would like to achieve is a method of UITableViewController's (from ContactTab).</p>
  
  <p>So far I tried this:
  When I tried to achieve the UItabbarController:</p>
  
  <pre><code>MainMenuClient *menu;
  UITabBarController *tabBarControllerchange = [[UITabBarController alloc] init];
  tabBarControllerchange = menu.tabBarController;
  [tabBarControllerchange setSelectedIndex:0];
  </code></pre>
  
  <p>When I tried to achieve the UITableViewController:</p>
  
  <pre><code>ContactListTab *contactListTab;
  [contactListTab updateCellData];
  </code></pre>
  
  <p>Does anybody have an idea for this problem? Thanks. Balazs.</p>