0

前のViewControllerからラベルを取得し、次のView Controllerでそのラベルを表示していますが、テキストフィールドでラベルを編集したいので、これらのラベルをユーザーインタラクションを有効に設定しましたが、まだ機能していません

 -(void)setDataOnForm
{
    nameLbl.text=name;
    emailLbl.text=email;

    imageSelect.image=[MyCommonFunctions getImageFromDocuments:image];

    NSLog(@"image %@", image);

}

これが私の以前のViewControllerです

- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
{
 user *worddc=[dataArray objectAtIndex:[indexPath row]];
    profileVC *pvc =[[profileVC alloc]initWithNibName:@"profileVC" bundle:nil];
   [self.navigationController pushViewController:pvc animated:YES];
    pvc.getid=worddc.user_id;
    pvc.name=worddc.name;
    pvc.email=worddc.email;
    pvc.image=worddc.image;
   [pvc setDataOnForm];

}
4

2 に答える 2

2

テキストを編集する場合は、UILabel ではなく UITextFiled を使用してください。

于 2012-12-11T07:14:48.160 に答える
0

2 番目のビューで UITextField を作成し、使用します

 [textField setText:name];
于 2012-12-11T07:15:55.633 に答える