获取当前app的名称和版本号

2015-12-23  本文已影响110人  雨雪霏霏why

NSDictionary *infoDictionary = [[NSBundle mainBundle] infoDictionary];

// app名称

NSString *name = [infoDictionary objectForKey:@"CFBundleDisplayName"];

// app版本

NSString *version = [infoDictionary objectForKey:@"CFBundleShortVersionString"];

// app build版本

NSString *build = [infoDictionary objectForKey:@"CFBundleVersion"];

上一篇下一篇

猜你喜欢

热点阅读