I have following coding in my ViewDidLoad of ViewController
- (void)viewDidLoad {
[super viewDidLoad];
UIImageView* view = [[UIImageView alloc] initWithImage: [UIImage imageNamed: @"logo.png"]];
view.frame = CGRectMake(300, 200, 200, 350);
[self.view addSubview:view];
UILabel *label = [[UILabel alloc] initWithFrame:CGRectMake(300, 800, 200, 50)];
label.textColor = [UIColor blackColor];
[label setBackgroundColor:[UIColor clearColor]];
[label setFont:[UIFont systemFontOfSize:30]];
[label setText: @"Tap to Enter"];
[self.view addSubview:label];
[label release]; }
- (void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event {
NSLog(@"Hello, You Tapped !"); }
Now I want to tap and switch to another controller and I want UITabBarController their, how can I do that?
If anyone is not clear, may ask again to me
You can call the new controller as modelviewController..That is one option..and in the viewDidLoad of the newController init tabController there..
.Or If you want push navigation from right to left..You can animate the view of the new Controller from right to left and push the view of current controller outside to the left of the screen..another option..but I recommend first one…