Advertise Mobile SDKs Books Events Forum News Social Networking Support Us
Follow @iphonedevsdk on Twitter

Interface 2, Advanced iOS
Mockup & Code Gen
($9.99)

Make your own iPhone apps
and run them live!
(free)

Pic Frame Dynamo: Photo Editing
($0.99)

Abiliator
($1.99)

Want your application or service advertised on iPhone Dev SDK?

Go Back   iPhone Dev SDK Forum

View Single Post
Old 03-05-2009, 01:10 AM   #1 (permalink)
coding
Registered Member
 
Join Date: Jan 2009
Posts: 11
coding is on a distinguished road
Default Access self.navigationController in a pushed ViewController

Hello,

I've got a problem, which I can't figure out with the docs.

I got a class, named CustomViewController, which subclasses UIViewController.

In AppDelegate I got a property customNavController, which is connected to a TabBarController from MainWindow.xib. I created an object from class CustomViewController (which comes from CustomViewController.xib) and push it on the customNavController. It appears and works fine, but I need to send the navigationController property inside the CustomViewController object to an instance object. The problem is, inside the the method initWithNibName:bundle: of the CustomViewController, the navigationController property is nil. Also in viewDidLoad: (which is called before initWithNibName:bundle:, which I also don't understand) it is not valid (0x0). Can someone explain me this?

Code in AppDelegate:

Code:
CustomViewController *customViewController = [[[CustomViewController alloc] initWithNibName:@"CustomViewController" bundle:nil] autorelease];

[customNavController initWithRootViewController:customViewController];
Please help, I have done a lot of recherche work already with no result.

Thanks in advance.

kind regards, Phil
coding is offline   Reply With Quote
 

» Advertisements
» Online Users: 431
21 members and 410 guests
7twenty7, acegames, baja_yu, Byfone, ChrisYates, Duncan C, foany, haisergeant, hussain1982, jbro, mer10, monu_rastogi, mraalex, nyoe, PavelMik, QuantumDoja, rraagg, ryantcb, TheStalker, TheTakeOver, v1n2e7t
Most users ever online was 1,387, 04-10-2012 at 04:21 AM.
» Stats
Members: 175,634
Threads: 94,096
Posts: 402,801
Top Poster: BrianSlick (7,990)
Welcome to our newest member, nyoe
Powered by vBadvanced CMPS v3.1.0

All times are GMT -5. The time now is 09:17 AM.
Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.