把UIImage 轉換爲NSData,而後拿到NSData的大小spa
NSData * imageData = UIImageJPEGRepresentation(image,1); length = [imageData length]/1000; NSLog(@"image-kb:%d kb,image-M:%d M", length, length/1024);