标签:android
public String getVersion() { PackageManager pm = getPackageManager(); try { PackageInfo packageInfo = pm.getPackageInfo(getPackageName(), 0); return packageInfo.versionName; } catch (NameNotFoundException e) { e.printStackTrace(); // can't reach return ""; } }
PackageManager 包管理者 获取当前应用程序的版本号,布布扣,bubuko.com
PackageManager 包管理者 获取当前应用程序的版本号
标签:android
原文地址:http://blog.csdn.net/feecooling/article/details/38492237