我有一个带有多单元格的 uitableview。其中包含文本文件,当我在文本字段上输入文本并滚动表格视图时,输入的文本正在擦除我的代码是
static NSString *CellIdentifier = @"Cell";
ComplaintsCustomCell *cell=(ComplaintsCustomCell*)[tableView dequeueReusableCellWithIdentifier:nil];
if(cell==nil){
NSArray *topLevelObjects = [[NSBundle mainBundle] loadNibNamed:@"ComplaintsCustomCell" owner:self options:nil];
for(id currentObject in topLevelObjects){
if([currentObject isKindOfClass:[UITableViewCell class]]){
cell = (ComplaintsCustomCell *) currentObject;
break;
}
}
}
cell.selectionStyle=UITableViewCellSelectionStyleNone;
NSDictionary *dict=[array1 objectAtIndex:indexPath.row];
cell.complaintID_label.text=[dict valueForKey:@"ProblemName"];
if(cell.notesView!=nil)
cell.notesView.text=[dict valueForKey:@"Notes"];
[cell.notesView setTag:indexPath.row +6000];
cell.durationFld.text=[dict valueForKey:@"Duration"];
[cell.durationFld setTag:indexPath.row + 5000];
cell.durationFld.delegate=self;