草庐IT

SELECTOR

全部标签

ios - -[GKPlayerInternal setAuthenticateHandler :]: unrecognized selector sent to instance

使用此日志获取错误SIGABRT:“-[GKPlayerInternalsetAuthenticateHandler:]:无法识别的选择器发送到实例”我在iPad3iOS5.1.1上测试了这个GKLocalPlayer*localPlayer=[GKLocalPlayerlocalPlayer];localPlayer.authenticateHandler=^(UIViewController*viewController,NSError*error)//errorhere{/*somecode*/};在iOS6上这个工作正常 最佳答案

iphone - Xcode 4/LLVM 3.0——让它更智能地处理 "no known instance method for selector"错误?

下面的代码是绝对安全的,但是Xcode4给我一个错误:if([selfrespondsToSelector:@selector(foo)])[selffoo];我知道我可以使用虚拟协议(protocol)来绕过它,但我经常使用这种模式,而且我觉得应该不需要那么多的工作。有什么办法可以在某处设置一个设置,最好是设置一次,这样这个“错误”就不会再困扰我了吗? 最佳答案 if([selfrespondsToSelector:@selector(foo)])[selffoo];如果没有参数也没有返回值,则该表达式仅“完全安全”。如果需要任何

ios - -[UIView setAdUnitID1 :]: unrecognized selector sent to instance

我已经创建了一个UIViewlibLinOneSdk.a的静态库。所以当我使用它的属性或功能时,我会崩溃。但如果我使用LinDFPBanner.m一切正常,在Storyboard中我也将它卡在了nib中。我进行了搜索,但不知道为什么在静态库中会发生这种情况。问题可能出在库搜索路径。任何人都可以帮助我如何提供库搜索路径。self.linBannerView.adUnitID1=@"XXXX";self.linBannerView.rootViewController1=self;此外,应用程序在ipodtouch5和ipadmini中运行良好。在模拟器和iphone5s中崩溃。这可能是建

iOS - [Fabric firebaseMode] : unrecognized selector sent to instance

我尝试按照此处提供的手动说明集成Crashlytics3.9.0ManualSteps.我看到集成成功并且能够强制应用程序崩溃,但是,当应用程序下次启动时,我在结构中看到以下崩溃。堆栈跟踪如下:[Crashlytics]Version3.9.0(125)[Crashlytics:Crash:Reports]Packagedreportwithidforsubmission[Crashlytics:Crash:Reports]Submittingreport[Crashlytics:Crash:Reports]Submittingasync/var/mobile/Containers/D

ios - -[_UIFlowLayoutSection 中心] : unrecognized selector sent to instance

我该如何修复这个崩溃:-[_UIFlowLayoutSectioncenter]:unrecognizedselectorsenttoinstance.我在做:UICollectionViewFlowLayout*collectionLayout=[[UICollectionViewFlowLayoutalloc]init];collectionLayout.minimumInteritemSpacing=0.0;collectionLayout.minimumLineSpacing=0.0;collectionLayout.sectionInset=UIEdgeInsetsMake(

iphone - 圆弧错误 : receiver type for instance message does not declare a method with selector

我遇到了这个我无法弄清楚的错误。error:AutomaticReferenceCountingIssue:Receivertype'pageAppViewController'forinstancemessagedoesnotdeclareamethodwithselector'createContentPages'我在下面发布了我的代码。我的类pageAppViewController中确实有一个名为createContentPages的方法。这是什么意思,是什么原因造成的?//contentViewController.m#import"contentViewController

iphone - 代码错误 : No visible @interface for masterViewController declares the selector

我遇到了一个似乎相当普遍的问题,但我无法弄清楚我的代码具体有什么问题。我搜索了stackoverflow并阅读了至少十几篇与我的相似的帖子,但我无法弄清楚我的个人问题。基本上,我试图将NSMutableDictionary从模态视图传递到主视图。这是代码:QuoteMasterViewController.h:@classQuoteModalViewController;@interfaceQuoteMasterViewController:UITableViewController@endQuoteMasterViewController.m:#import"QuoteMasterV

ios - -[__NSCFConstantString 大小] : unrecognized selector sent to instance . ..?

redSegmentedControl.mredSegmentedControl.h现在,我在另一个Controller中编写代码//self.segmentedControl=[[redSegmentedControlalloc]initWithFrame:CGRectMake(0,140,320,50)];self.segmentedControl=[[redSegmentedControlalloc]initWithSectionImages:@[@"list.png",@"list.png",@"list.png"]sectionSelectedImages:@[@"list.

ios - -[UITableViewController setManagedObjectContext :]: unrecognized selector sent to instance 0x7490da0'

我知道错误发生在这一行,因为应用程序在注释掉这一行的情况下工作正常:controller.managedObjectContext=self.managedObjectContext;错误是:Terminatingappduetouncaughtexception'NSInvalidArgumentException',reason:'-[UITableViewControllersetManagedObjectContext:]:unrecognizedselectorsenttoinstance0x7490da0'fibroMappAppDelegate.h////fibroMap

ios - [__NSCFString 字符值] : unrecognized selector sent to instance?

我的应用程序使用FMDB和Mantle,在iPhone5模拟器之后一切正常,但在iPhone5s之前崩溃,看起来BoolVariable是原因。但我不明白为什么在iPhone5s、6和6plus上一切正常。@property(nonatomic,assign)BOOLisMyFan;@property(nonatomic,assign)BOOLisMyFollow;@property(nonatomic,assign)NSIntegercityID;@property(nonatomic,assign)NSIntegerprovinceID;@property(nonatomic,as