开发者

How to PUT image downloaded with ASIHTTPrequest in a UIImageView

开发者 https://www.devze.com 2023-03-07 20:21 出处:网络
i want to display an image downloaded with ASIHTTPrequest in a UIIamgeView . I tried this : NSData *responseData = [request responseData];

i want to display an image downloaded with ASIHTTPrequest in a UIIamgeView . I tried this :

NSData *responseData = [request responseData];
    promotionPicture.image = responseData;

But don't work开发者_开发知识库 , incompatible type ... help Please


I believe you'll need to wrap the NSData in a UIImage:

promotionPicture.image = [UIImage imageWithData:responseData];
0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号