ios - CUICatalog: Invalid asset name supplied: , or invalid scale factor: 2.000000 -
I have a UiVIEW controller in which I have drawn a table view and have inserted all necessary connections such as delegate and data source and It works just fine, everything is great I tried to set the background to this table view and I got this strange error
CUICatalog: Invalid property name given, or invalid Scale factor: 2.000000 I used this method Try to set Rishtbhumi of:
UIImageView * tempImageView = [[UIImageView alloc] initWithImage: [UIImage imageNamed: @ "mypredictions_bg.png"]]; [TempImageView setFrame: self.tableView.frame]; Self.tableView.backgroundView = tempImageView; What am I missing? I have checked that the name of the picture is correct
I have created a debug class, So that you
you need to install JRSwizzle to use it. #import "UIImageDebugger.h" #import "JRSwizzle.h" @ Implementation UIImageDebugger + (Zero) startDebugging {Fixed Dispatch_ENC_T once; Disappear_onces (and once, ^ {NSError * error = NULL; [UIImage jr_swizzleClassMethod: @selector (imageNamed :) withClassMethod: @Selector (hs_xxz_imageNamed :) Error: & Error]; if (error) {NSLog (@ "error Setting up UIImageDebugger:% @ ", error);} and {NSLog (@" !!!!!!!!!!!!!!!!!!!! UIImage swizzle in effect - take it out for release !! ");}}); } @ And @ interface UIImage (UIViewDebugger) + (UIImage *) hs_xxz_image Nominated: (NSString *) name; @end @implementation UIImage (UIViewDebugger) + (UIImage *) hs_xxz_image Named: (NSString *) name {if (! name) {NSLog (@ "null image name at \ n% @", [NSThread callStackSymbols]); } UIImage * image = [self-hs_xxz_image nominated: name]; If (! Image) {failed to create image on {@ @ @ @ @ @ @ (@nosthread callStackSymbols)); } Return image; } @end
Comments
Post a Comment