title: "use of undeclared identifier" error in Objective-C
body: <p>I have been following a tutorial about parsing json with Xcode but have come across issues that i cant resolve.  I suspect they are because the tutorial is using 5.1 and i am using 6.1</p>
  
  <p>AppDelegate.m 
  unused variable 'navController'
  use of undeclared identifier 'navController'
  See below</p>
  
  <pre><code>@implementation AppDelegate
  
  - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
  {
      self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
      // Override point for customization after application launch.
      if ([[UIDevice currentDevice] userInterfaceIdiom] == UIUserInterfaceIdiomPhone) {
          self.viewController = [[ViewController alloc] initWithNibName:@"ViewController_iPhone" bundle:nil];
          UINavigationController *navController = [[UINavigationController alloc] initWithRootViewController: self.viewController];
      } else {
          self.viewController = [[ViewController alloc] initWithNibName:@"ViewController_iPad" bundle:nil];
          UINavigationController *navController = [[UINavigationController alloc] initWithRootViewController: self.viewController];
      }
      self.window.rootViewController = navController;
      [self.window makeKeyAndVisible];
      return YES;
  }
  </code></pre>
  
  <p>ViewController.m
  Expected method body
  Use of undeclared identifier 'theData'</p>
  
  <pre><code>- (void)connection:NSURLConnection *)connection didReceiveData:(NSData *)theData
  {
      [data appendData:theData];
  }
  </code></pre>