ADDING MULTIPLE VIEWS TO VIEW CONTROLLER INSIDE A TAB CONTROLLER

Tarun Kumar

Total Post:214

Points:1642
Posted by  Tarun Kumar
 652  View(s)
Ratings:
Rate this:

I have a tabview controller to which I added a UIViewController to each tab. I want to have multiple UIViews inside the UIViewController.

So in the implementation of the UIViewController class I added [self.view addSubView:uiview1] and [self.view addSubView:uiview2]. The problem is that when I run the app, it crahes on load.

However, if I only used a single UIView and did: self.view = UIView1 that would work fine.

Does anyone know what is causing the problem? Or if I'm doing something fundamentally wrong?

Answer

NEWSLETTER

Enter your email address here always to be updated. We promise not to spam!