I am getting the image's URL at run time and download & display these images in a table. Images are downloading asynchronously(using SDWebImage). What is more important is that I want to display all these images with their actual sizes. First time ,the table is loading fine, I have more than 5 section(each section contains one row) and when I scroll the table and try to update sections by using reloadSections, then the table shows with wrong cell image height. Can anybody help me out with this? Note: I am using UITableViewAutomaticDimension
[_imageViewSharedImage sd_setImageWithURL:[NSURL URLWithString:[_popUpManager.popUpDetails valueForKey:@"photo"]] placeholderImage:[UIImage imageNamed:@"placeholderBackground"] options:SDWebImageProgressiveDownload completed:^(UIImage *image, NSError *error, SDImageCacheType cacheType, NSURL *imageURL)
{
UIImage *croppedImage=[Util adjustImageSizeWhenCropping:image];
[_imageViewSharedImage setFrame:CGRectMake(_imageViewSharedImage.frame.origin.x,_imageViewSharedImage.frame.origin.y,croppedImage.size.width,croppedImage.size.height)];
[_imageViewSharedImage setImage:croppedImage];
[self setNeedsLayout];
[self updateConstraintsIfNeeded];
}];