iphone - NSInvalidArgumentException exception when adding image to imageView iOS -


.फ़ाइलें

  @property (मजबूत, nonatomic) LAClaimReport * दावे रिपोर्ट;   

। फ़ाइल

  @ इंटरफेस LACreateReportViewController () {NSArray * _thumbnails; लापोटो टहौब्स * _last चुने गए फोटो; } _ थंबनेल = _claimReport.photos.allObjects; यदि (_ थंबनेल count & gt; 0) {_photosCaption.textColor = [UIColor colorWithRed: 0 / 255.0 हरा: 46 / 255.0 नीला: 91 / 255.0 अल्फा: 1]; UIImageView * image = [[UIImageView alloc] initWithFrame: CGRectMake (30, 1838, 300, 600)]; एनएसएलॉग (@ "छवि:% @", _ थंबनेल [0]); [छवि सेट छवि: (UIImage *) _ थंबनेल [0]]; // यहां अपवाद }   

NSInvalidArgumentException ', कारण:' - [Laphoto आकार]: अपरिचित चयनकर्ता को उदाहरण के लिए भेजा गया 0xa76b720 '

तस्वीरें एक स्तंभ है LAClaimReport की क्लास फ़ाइल आकार के बारे में मैं क्या याद कर रहा हूँ यहाँ? Pls गाइड।

_ थंबनेल इसमें UIImage उदाहरण, इसमें कुछ अन्य प्रकार के ऑब्जेक्ट शामिल हैं

आकार UIImage पर एक विधि है जो कि छवि दृश्य द्वारा उपयोग की जाती है, यह बताने के लिए पर्याप्त जानकारी शामिल नहीं है _thumbnails उस विधि को लागू नहीं करता है।

आपका NSLog (@ "image:% @", _ थंबनेल [0]); को क्लास प्रकार को सूचीबद्ध करना चाहिए जिसे आप एक छवि के रूप में उपयोग करने का प्रयास कर रहे हैं।

Comments

Popular posts from this blog

c# - The item with identity 'Id' already exists in the metadata collection. Parameter name: item -

sql - PostgreSQL automatically update row at specific date -

jsp - No mapping found for HTTP request with URI with annotation config Spring MVC and Jetty -