I want to create uitabbarviewcontroller programmatically for my application.
In that uitabbarcontroller, i want to add 2 buttons namely "Show Log", "My Contacts".
when tapping on that "ShowLog" button , i want to push new view and the same for "My Contacts" button also
I dont know how to do that
Please help me below is the code i have tried
myTabBarController = [[UITabBarController alloc] init];
myTabBarController.view.frame = CGRectMake(0, 0, 320, 460);
MyCallLogViewController *testVC = [[MyCallLogViewController alloc] init];
TemplateViewController *otherVC = [[TemplateViewController alloc] init];
NSArray* controllers = [NSArray arrayWithObjects:testVC, otherVC, nil];
myTabBarController.viewControllers = controllers;
// Add the tab bar controller's current view as a subview of the window
[self.view addSubview:myTabBarController.view];