Search code examples
iphonexcodeuinavigationcontrolleruipagecontrolrootview

Xcode: Navigationcontroller loading UIpagecontrolled view?


users,

i have a problem i cant get my head around, i hope you could help me out;

I'm building a small iphone app that will basically have a topbar(image), groundbar (image) and in the middle a middlebar (scrollview) which is used for PageControll.

All is fine until i tell IB that my rootViewController is a navcontroller. The pagecontrol isnt interactive anymore and it seems like its just displaying the view. The purpose of the navcontroller will be to push a new view when someone double taps on the scrollview area.

Do i have to define the PageController to be a childcontroller of the rootController NavController? Or isnt the PageController a controller at all and do i have to seperate the scrollview from the main delegate?

I hope someone can shed some light on my problem; thanks in advance!

Best regards, btz


Solution

  • UINavigationController objects hold other ViewController objects. You do not manipulate any views from the navigationController, instead, you push the viewController whose views you want to display on the navigationController's stack.

    I can't be more specific than that until you get more specific, for instance by posting some code.