編輯後獲取無法識別的選擇:我發現這裏的解決方案SDWebImage : setImageWithURL fails when used to set image of a UITableViewCell刪除其他框架
我的影片利用SDWebImage的UITableView和它的工作很好,但我決定從我的應用程序中刪除ShareKit。我相信我所做的只是刪除ShareKit,刪除對它的任何引用,然後重新安裝ObjectiveFlickr,JSONKit和LFWebAPIkit。所有這些我都沒有在這張表中使用。在我這樣做之後,除了這個tableview之外,一切都正常。
,我得到這個錯誤:
-[UIImageView setImageWithURL:placeholderImage:]: unrecognized selector sent to instance 0x86b31a0
有我沒有問題彙編,並與自動完成,我甚至刪除,readdded SDWebImage但它不會做任何事情。一切都正常運行,但是當它試圖用的UIImageView加載該表是在這一行立即崩潰:
[cell.imageView setImageWithURL:[v thumbURL] placeholderImage:[UIImage imageNamed:@"46-movie-2.png"]];
這裏是我的代碼:
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
static NSString *CellIdentifier = @"YTVVideoTableCell";
YTVVideoTableCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier];
if (cell == nil) {
cell = [[YTVVideoTableCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:CellIdentifier];
}
Video *v = [[[VideoStore sharedStore] allItems] objectAtIndex:[indexPath row]];;
[cell.imageView setImageWithURL:[v thumbURL] placeholderImage:[UIImage imageNamed:@"46-movie-2.png"]];
[cell setController:self];
[cell setTableView:[self tableView]];
[[cell titleLabel] setText:[v title]];
[[cell titleLabel] alignBottom];
return cell;
}
的什麼地方出了錯任何想法當我刪除ShareKit?任何想法如何排除故障?
可能重複[SDWebImage:setImageWithURL失敗時,用於設置圖像的UITableViewCell](http://stackoverflow.com/questions/8504953/sdwebimage-setimagewithurl-fails-when-used-to-set-image-of -a-的UITableViewCell) – 2012-08-14 05:25:10