I have next object in xib:
- UIWindow
- UIView1
- UIView2
- UIViewController
When run project I see UIWindow only. What exectly should I write for UIView switching? Should I delete UIWindow and use UIViewController and UIViews only?
Thanks
first of all, you should read the basics on what parts make an iphone app, because you cannot delete the UIWindow, it's necessary to display your application. Seems to me like you need to read the basics of objective-C in general.
When your application loads you need to add a subview (a UIView) to UIWindow that you want to be displayed (actually, you don't NEED to do that, but you should). It's good practice to nest that subview in a UIViewController. You need a second UIView that you want to get displayed later, and you need some kind of mechanic that switches between the two views (a button?). when the user wants to switch to the other view (presses the button?) you simply remove the view that is currently displayed in your windows via the removeFromSuperview method. after that, you add the new view to your window via addSubview - that's it.