开发者

How set [self varNavigationController] for not being null in my ViewController?

noob writing,

I'm trying to use a Navigation Controller, but the method pushViewController doesn't work as it is 'null'.

At the same time I've tried the same code in a Navigation Based App Template, and I can do it work.

My question is, how can I make that [self myVariableforNav开发者_运维问答igationController] not to be null in my ViewBased App?? I've tried everything inside the AppDelegate but without success.

Thank you very much!!!


Here you can add your own navigation controller. And assign as it with the main controller to root viewcontroller.

Now when you want to push to another view you can easily do it as your view based application have the navigationcontroller as the rootViewCOntroller. So, you can't have the value to null from now onwards and you can push to second view easily.

Let me know if still having doubt.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜