This is a sample manifest. Is it possible to access the attribute versionCode and versionName from Java? How? Copy
Solution 2:
for version code:
int versionCode = getPackageManager().getPackageInfo(getPackageName(), 0).versionCode;
for version name:
StringversionName= getPackageManager().getPackageInfo(getPackageName(), 0).versionName;
Post a Comment for "Access Android Manifest Attributes In Java"