ios - To Click Button Pass Json Data To Other ViewCont``roller Tableview -


i developing ios app..click on button pass json array other uiviewcontroller tableview show data in tableview..in tableview array data pass on nsdictionary , use dictionary object. error [__nscfdictionary objectatindex:]: unrecognised selector sent instance 0x7b115560']...thanks in advance

// button click     bbauthordetailviewcontroller *bbauthordetail =[[uistoryboard storyboardwithname:@"main" bundle:nil]instantiateviewcontrollerwithidentifier:@"bbauthordetail"];           [bbauthordetail setselectiontype:bbselectionauthorname];         _serverobj = [[server alloc]init];          [_params setobject:_addetailsobj.authordetail forkey:@"author"];         [_serverobj bbauthornamewithparams:_params];      // bbauthordetail.data=resultsarray;     //nsindexpath *indexpath = [bbauthordetail.tableview indexpathforselectedrow];            bbauthordetail.data = [resultsarray objectatindex:indexpath.row];            nslog(@"%@",resultsarray);       //[bbauthordetail setmanagedobjectcontext:self.managedobjectcontext];     [self.navigationcontroller pushviewcontroller:bbauthordetail animated:yes];  uiviewcontroller table show data  - (nsinteger)numberofsectionsintableview:(uitableview *)tableview {     return 1; }  - (nsinteger)tableview:(uitableview *)tableview numberofrowsinsection:(nsinteger)section {     return _data.count; }  - (uitableviewcell *)tableview:(uitableview *)tableview cellforrowatindexpath:(nsindexpath *)indexpath {     nsstring *cellidentifier = [nsstring stringwithformat:@"cell-%li", (long)indexpath.row];     bbadscell *cell = [tableview dequeuereusablecellwithidentifier:cellidentifier];    //   addetails *_addetailsobj = (addetails *)[_data objectatindex:indexpath.row];       // nsdictionary  *dic = [_data objectatindex:indexpath.row];     //addetails *_addetailsobj = [[addetails alloc]init];      if (cell == nil) {         cell = [[bbadscell alloc] initwithstyle:uitableviewcellstyledefault reuseidentifier:cellidentifier];         cell.row = indexpath.row;         //[cell setdelegate:self];     }   // error part      nsdictionary *dic = [_data objectatindex:0];       cell.textlabel.text = [dic objectforkey:@"post_author"];     return  cell; } 


Comments

Popular posts from this blog

google chrome - Developer tools - How to inspect the elements which are added momentarily (by JQuery)? -

angularjs - Showing an empty as first option in select tag -

php - Cloud9 cloud IDE and CakePHP -