In Android, How I can get app installed date and how I can get installed app size.
I am using below code to get app size but it is not correct
List packs = getPackageManager().getInstalledPackages(0);
for(i=0;i<packs.size();i++) {
PackageInfo p = packs.get(i);
ApplicationInfo appInfo =p.applicationInfo;
long fileSize = new FileInputStream(appInfo.sourceDir).getChannel().size();
}
Please help me.. Thanks,
Go to App section and from 3 dot menu click view and select Medium detail. Now it will show App details like version number, size and date of installation.
You can view the app download history in Google Play Store from the Installed or Library sections of the Store. The Installed section shows you all the apps currently installed on your Android device.
Ajay,
To get the installation date you will want to use the PackageManager
class. More specifically the getPackageInfo()
method. This will return to you a PackageInfo
object which contains firstInstallTime
value.
There does not currently exist a public API to get an application's size as PackageManager.getpackageSizeInfo()
was removed from the API from SDK 0.9 to SDK 1.0. See HERE
Good luck!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With