私は最初の行にuiwebviewを含むテーブルビューを持っています。私は、ユーザーがボタンをクリックすると、このテーブルのwebviewオブジェクトを新しいものに変更したいと思います。私は以下のコードを使用していますが、うまく動作しません。私はwebviewを再作成しますが、古いオブジェクトはそこにあり、新しいオブジェクトがあります。古いセルをセルから削除するにはどうすればよいですか?更新uitableviewセルオブジェクト
おかげで...
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
static NSString *CellIdentifier = @"Cell";
UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier];
if (cell == nil) {
NSLog(@"NİL.......");
cell = [[[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:CellIdentifier] autorelease];
} else {
NSLog(@"NOT NİL.......");
}
[cell addSubview:webView];
return cell;
}