在Xcode中手动设置构建版本和版本号很容易,我学习了如何在构建时使用宏来增加它们.但是如何在代码中引用它们的值?
如何打印int*(int指针)和unsigned int*在日志中使用NSLog?
- (int) doSomethingWith:(unsigned int)Msg withWparam:(unsigned int*)wParam withParameter:(int *) lParam
{
NSLog(@"MSg:%d wParam:%u lParam:%u",Msg,wParam,lParam);
//not working
return 1;
}
Run Code Online (Sandbox Code Playgroud)
警告: Format specifies type 'unsigned int' but the argument has type 'unsigned int *'
我想使用导航栏,我意识到它有title和prompt.
他们之间有什么区别?
我self = [super init]在init方法中看到过.我不明白为什么.不会[super init]返回超类?如果我们指出self = [super init],我们没有得到self = superclass?
这是一个示例代码片段
- (id)init
{
if (self = [super init]) {
creationDate = [[NSDate alloc] init];
}
return self;
}
Run Code Online (Sandbox Code Playgroud)
希望有人能为我澄清一下.谢谢.
我一直收到这个警告,任何人都可以提供错
ld: warning: ignoring file /Applications/Xcode.app/Contents/Developer/Platforms /iPhoneOS.platform/Developer/SDKs/iPhoneOS5.1.sdk/System/Library/Frameworks//SystemConfiguration.framework/SystemConfiguration, missing required architecture armv7 in file
Undefined symbols for architecture armv7:
"_SCNetworkReachabilityCreateWithAddress", referenced from:
+[Reachability reachabilityWithAddress:] in Reachability.o
"_SCNetworkReachabilityCreateWithName", referenced from:
+[Reachability reachabilityWithHostName:] in Reachability.o
"_SCNetworkReachabilityUnscheduleFromRunLoop", referenced from:
-[Reachability stopNotifier] in Reachability.o
"_SCNetworkReachabilityScheduleWithRunLoop", referenced from:
-[Reachability startNotifier] in Reachability.o
"_SCNetworkReachabilitySetCallback", referenced from:
-[Reachability startNotifier] in Reachability.o
"_SCNetworkReachabilityGetFlags", referenced from:
-[Reachability connectionRequired] in Reachability.o
-[Reachability currentReachabilityStatus] in Reachability.o
ld: symbol(s) not found for architecture armv7
clang: error: linker command failed with exit code 1 …Run Code Online (Sandbox Code Playgroud) 如何强制UISearchBar自动开始新搜索(例如按"搜索"按钮)?有没有一种简单的方法来实现这一目标?
我一直在负责使用更新我们的代码org.apache.commons.lang来org.apache.commons.lang3和我发现,新版本StringEscapeUtils不再有法escapeJavaScript()但我们是在我们整个代码不少地方用这个.
我一直在阅读文档,看起来整个都StringEscapeUtils被重写了lang3(参见发行说明lang 3.3.2),并且他们删除了这些重写,escapeJavaScript()但他们没有说明在任何文档中使用什么作为替代(不是我能看到的).这是什么新文档.
所以我的问题是我不能成为唯一一个注意到这一点并且经历过这个问题的人,那么使用什么替代方案StringEscapeUtils.escapeJavaScript()呢?
我从新的iTunes Connect中的提交队列中删除了我的构建.现在,当我向应用程序商店提交新版本时,它们会显示在"预发布"下,但不会显示在"版本"下.所以现在在我的应用程序信息中它只是说"1.0准备出售1.0.25开发人员被拒绝".
在"版本"下我只看到1.0和1.0.25.在"预售"下,我看到很多新版本,最高可达1.0.31.
我做错了什么?
没有选择像以前那样创建新版本.从Xcode 6.0.1上传后我也没有收到电子邮件.Xcode上传的结果都很成功,并给了我一条感谢信息.
我使用iOS 8 objective-c.我从联系人列表中选择联系人后收到此消息.
插件com.apple.MobileAddressBook.ContactsViewService无效
该消息怎么办?
谢谢
objective-c ×6
ios ×5
cocoa-touch ×1
iphone ×1
java ×1
nslog ×1
stack-trace ×1
uisearchbar ×1
version ×1
xcode ×1
xcode4 ×1