码迷,mamicode.com
首页 > 移动开发 > 详细

如何动态获取ios工程的Bundle version版本号,bundleID,appName

时间:2016-04-14 15:43:45      阅读:200      评论:0      收藏:0      [点我收藏+]

标签:

获取 bundle version版本号

+(NSString*) getLocalAppVersion

{

    return [[[NSBundle mainBundle] infoDictionary] objectForKey:@"CFBundleShortVersionString"];

}

 获取BundleID

+(NSString*) getBundleID

{

    return [[[NSBundle mainBundle] infoDictionary] objectForKey:@"CFBundleIdentifier"];

}

 获取app的名字

+(NSString*) getAppName

{

    NSString *appName = [[[NSBundle mainBundle] infoDictionary] objectForKey:@"CFBundleDisplayName"];

    NSMutableString *mutableAppName = [NSMutableString stringWithString:appName];

}

如何动态获取ios工程的Bundle version版本号,bundleID,appName

标签:

原文地址:http://www.cnblogs.com/dashengios/p/5391076.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!