Alex Rivera | Logout

NSData and UIImage

Asked 2008-11-02T21:22:53.503
60

I am trying to load UIImage object from NSData, and the sample code was to NSImage, I guess they should be the same. But just now loading the image, I am wondering what's the best to troubleshoot the UIImage loading NSData issue.

Edit
Report

1 Answer

3

theData should be a NSData object which already contains the data. You need to do the file loading/downloading to the NSData object before it is used. You can inspect it by using NSLog on theData and see if it contains the valid data.

answered 2008-11-03T08:25:30.390

Your Answer