草庐IT

Undeclared

全部标签

iphone - 编译到 iOS 设备时出现 "Variable Undeclared"错误,但不适用于模拟器

我有一个自定义的UIVIewController,它是其他Controller的基类,并且有一个自定义UIView变量的实例,该实例由继承的类访问。BaseViewController.h@interfaceBaseViewController:UIViewController{UIView*_vwHeader;}@endBaseViewController.m#import"BaseViewController.h"@implementationBaseViewController-(void)loadView{[superloadView];_vwHeader=[[UIViewal

iphone - 编译到 iOS 设备时出现 "Variable Undeclared"错误,但不适用于模拟器

我有一个自定义的UIVIewController,它是其他Controller的基类,并且有一个自定义UIView变量的实例,该实例由继承的类访问。BaseViewController.h@interfaceBaseViewController:UIViewController{UIView*_vwHeader;}@endBaseViewController.m#import"BaseViewController.h"@implementationBaseViewController-(void)loadView{[superloadView];_vwHeader=[[UIViewal

ios - 如何处理 `Use of undeclared identifier ' UIDevice'`

我是按照MD文件一步步来的。但是编译还是有错误。我能做什么?在FaceppClient.m文件中:if([[[UIDevicecurrentDevice]systemVersion]compare:@"5.0"options:NSNumericSearch]!=NSOrderedAscending)_ios50orNewer=true;Xcode输出这个错误:Useofundeclaredidentifier'UIDevice'我在文件中添加了#import"UIDevice.h",但是Xcode输出"UIDevice.hnotfound"。我在项目中添加了UIKit框架,但我仍然遇到

ios - 如何处理 `Use of undeclared identifier ' UIDevice'`

我是按照MD文件一步步来的。但是编译还是有错误。我能做什么?在FaceppClient.m文件中:if([[[UIDevicecurrentDevice]systemVersion]compare:@"5.0"options:NSNumericSearch]!=NSOrderedAscending)_ios50orNewer=true;Xcode输出这个错误:Useofundeclaredidentifier'UIDevice'我在文件中添加了#import"UIDevice.h",但是Xcode输出"UIDevice.hnotfound"。我在项目中添加了UIKit框架,但我仍然遇到

ios - Xcode AdMob 的 GAD_SIMULATOR_ID undeclared identifier 报错

我昨天下载了AdMobSDKiOS7.0.0,并遵循了GoogleAdMob的iOS指南。GADRequest*request=[GADRequestrequest];request.testDevices=@[GAD_SIMULATOR_ID,@"2077ef9a63d2b398840261c8221a0c9b"];当我输入上述行时,我收到一个Xcode错误,指出“使用未声明的标识符‘GAD_SIMULATOR_ID’”但是,在GoogleAdMob的iOS指南中,它说明了如何在iOS设备上获取测试横幅。那么为什么它不起作用? 最佳答案

ios - Xcode AdMob 的 GAD_SIMULATOR_ID undeclared identifier 报错

我昨天下载了AdMobSDKiOS7.0.0,并遵循了GoogleAdMob的iOS指南。GADRequest*request=[GADRequestrequest];request.testDevices=@[GAD_SIMULATOR_ID,@"2077ef9a63d2b398840261c8221a0c9b"];当我输入上述行时,我收到一个Xcode错误,指出“使用未声明的标识符‘GAD_SIMULATOR_ID’”但是,在GoogleAdMob的iOS指南中,它说明了如何在iOS设备上获取测试横幅。那么为什么它不起作用? 最佳答案

ios - 在 Xcode 5 中抑制 "undeclared selector"警告

我有一个父ViewController和一个subviewController。在subviewController的View中,我有一个名为“startButton”的UIButton。对于那个按钮,我添加了一个目标,如下所示[startButtonaddTarget:[selfparentViewController]action:@selector(test:)forControlEvents:UIControlEventTouchUpInside];我已经在父Controller中实现了test:方法,这对我来说工作得很好。当点击按钮时,事件从subviewController

ios - 在 Xcode 5 中抑制 "undeclared selector"警告

我有一个父ViewController和一个subviewController。在subviewController的View中,我有一个名为“startButton”的UIButton。对于那个按钮,我添加了一个目标,如下所示[startButtonaddTarget:[selfparentViewController]action:@selector(test:)forControlEvents:UIControlEventTouchUpInside];我已经在父Controller中实现了test:方法,这对我来说工作得很好。当点击按钮时,事件从subviewController

ios - "use of undeclared identifier LOG_LEVEL_VERBOSE"消息的原因可能是什么

我正在尝试配置cocoalumberjack,当我添加ddLogLevel设置为LOG_LEVEL_VERBOSE时,XCode抛出“使用未声明的标识符”错误。这是为什么?如何避免? 最佳答案 Thisquestion表明清除DerivedData并重新启动Xcode可以解决此类错误。但是,您不应在预编译头文件中包含变量,因为它会包含在每个源文件中,并且前缀文件与普通头文件相比有些复杂。更好的方法是使用包含以下内容的Constants.h文件:externintddLogLevel;和#import将其放入您的前缀文件中。然后创建一

ios - "use of undeclared identifier LOG_LEVEL_VERBOSE"消息的原因可能是什么

我正在尝试配置cocoalumberjack,当我添加ddLogLevel设置为LOG_LEVEL_VERBOSE时,XCode抛出“使用未声明的标识符”错误。这是为什么?如何避免? 最佳答案 Thisquestion表明清除DerivedData并重新启动Xcode可以解决此类错误。但是,您不应在预编译头文件中包含变量,因为它会包含在每个源文件中,并且前缀文件与普通头文件相比有些复杂。更好的方法是使用包含以下内容的Constants.h文件:externintddLogLevel;和#import将其放入您的前缀文件中。然后创建一