本文介绍了xLode 4.5和iOS 6上的NSLocalization的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述 29岁程序员,3月因学历无情被辞! 有没有办法在iOS6的xCode 4.5中使用带有NSLocalizedString(@KEY,@)的Localizable.strings,就像在旧的iOS5中一样? 这是我的示例代码: In Localizable.strings KEY=Hello World!; 在.m脚本中 NSString * tempString = NSLocalizedString (@KEY,NULL); NSLog(@My String is:%@,tempString); iOS5.1的日志是:我的字符串是:Hello World! iOS6的日志是:我的字符串是:KEY ...我'我真的会变得疯狂!我的错误在哪里? 非常感谢!!!Is there any way to use Localizable.strings with NSLocalizedString(@"KEY", @"") in xCode 4.5 for iOS6 like in older iOS5?Here is my sample code:In Localizable.strings"KEY" = "Hello World!";In .m scriptNSString *tempString = NSLocalizedString(@"KEY", NULL);NSLog(@"My String is: %@", tempString);The log for iOS5.1 is: "My String is: Hello World!"The log for iOS6 is: "My String is: KEY"...I'm really going to become crazy! Where is my error?Thanks a lot!!!推荐答案他们无需创建新项目并复制,只需删除可本地化的文件,再创建一次,你会没事的。Their is no need to create a new project and copy, just delete the localizable files, create it once again and you will be fine. 这篇关于xLode 4.5和iOS 6上的NSLocalization的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持! 上岸,阿里云!
09-01 16:06