2012-10-08 64 views
0

2012-10-08 14:48:14.579 sageby [2716:907] *由於未捕獲的異常'NSInvalidArgumentException',原因:' - [SBJsonParser errorTrace]:無法識別的選擇發送到實例0x1fda4660' *第一擲調用堆棧: (0x352412a3 0x34a1397f 0x35244e07 0x35243531 0x3519af68 0x12932f 0x1293a7 0x12cda3 0x12c9b1 0x12c753 0x12aac7 0x12e567 0x12eac3 0x3a26bef5 0x3a1ab9f1 0x3a1ab90d 0x384ba5df 0x384b9ccb 0x384e2133 0x3518774d 0x384e2593 0x3844615d 0x35216683 0x35215ee9 0x35214cb7 0x35187ebd 0x35187d49 0x35ef02eb 0x37dcd301 0xaaaf1 0x39e0cb20) libC++ abi.dylib:終止調用拋出異常 (lldb)xcode在模擬器上運行良好,但部署到iOS 6遇到錯誤


//MBProgressHUD 
    MBProgressHUD *hud=[MBProgressHUD showHUDAddedTo:self.view animated:YES]; 
    [email protected]"Accessing account.."; 
    hud.labelFont=[UIFont fontWithName:@"Arial Rounded MT Bold" size:14]; 


      //URL GETTING 
      NSString *phpfile=[[NSString alloc]initWithFormat:@"http://dev.xxxx.com/pxxx/Module_MyPxxx/json_xxxx_xxx_info.php"]; 
      NSString *param_str=[[NSString alloc]initWithFormat:@"email=%@", mydelegate.overall_email]; 
      NSString *receivedDataAsString=[mydelegate phpConnection:param_str :phpfile]; 

      SBJsonParser *parser=[[SBJsonParser alloc]init]; 
      NSError *error=nil; 
      self.dic_user_info=[[parser objectWithString:receivedDataAsString error:&error]objectAtIndex:0]; 
      if(error) 
      { 
       NSLog(@"JSON Parser error! Reason: %@", error.localizedDescription); 
      } 



      //URL GETTING 
      phpfile=[[NSString alloc]initWithFormat:@"http://dev.xxx.com/pxxx/Module_MyPxxx/json_get_xxx_xxx_pxxx.php"]; 
      param_str=[[NSString alloc]initWithFormat:@"email=%@", mydelegate.overall_email]; 
      receivedDataAsString=[mydelegate phpConnection:param_str :phpfile]; 

      parser=[[SBJsonParser alloc]init]; 
      error=nil; 
      self.array_polls=[parser objectWithString:receivedDataAsString error:&error]; 
      if(error) 
      { 
       NSLog(@"JSON Parser error! Reason: %@", error.localizedDescription); 
      } 

     [self.tableView reloadData]; 
     [MBProgressHUD hideHUDForView:self.view animated:YES]; 
+0

可以顯示一些不遠的地方這個錯誤是來自該代碼?你在哪裏打電話「'errorTrace'」? –

+0

#進口 INT主(INT的argc,字符* argv的[]){ @autoreleasepool { INT retVal的= UIApplicationMain(的argc,argv的,零,無); return retVal; } } – user1615767

+0

你必須發佈你的代碼,而不是隻發佈錯誤輸出。但顯然,'SBJsonParser'對象/變量是'null'。 – Raptor

回答

0

嗨,我的應用程序的開發。

的問題是,在Xcode的4.5運行是正確的,但只是iPhone設備,它不會工作運行..

+0

iphone設備已更新至iOS6。 iOS6和iPhone模擬器x4.5之間可能會有一些不匹配嗎?感謝幫助! – dellgg

相關問題