Xcode6とXcode5でアプリ名(app nam)eを取得する方法比較

1.Xcode5 アプリ名(app name)を取得
NSString *proName = [[[NSBundle mainBundle] infoDictionary] objectForKey:@"CFBundleDisplayName"];
NSLog(@"dicName ==== %@",[[NSBundle mainBundle] infoDictionary]);

出力結果
CFBundleDisplayName = TestOfButton;
CFBundleName = TestOfButton;

2.Xcode6 アプリ名(app name)を取得
NSString *proName = [[[NSBundle mainBundle] infoDictionary] objectForKey:@"CFBundleName"];
NSLog(@"dicName ==== %@",[[NSBundle mainBundle] infoDictionary]);
出力結果:CFBundleName = TestOfButton;

3.Xcode6に info.string がありません、Info.plist のみある

IOS

Posted by arkgame