开发者

How to make an Android application use specific version of another application

I have to develop an Android application which should access a specific version of another application installed on the same machine. Is there a way we can handle this check programmatically? I am an Android开发者_Python百科 newbie. Any help would be greatly appreciated.

Thanks in Advance, Navin


Is there a way we can handle this check programmatically?

Use PackageManager and getPackageInfo() to get a PackageInfo object for the specific application, identified by its package (e.g., com.commonsware.mygreatapp). The versionCode and versionName fields on the PackageInfo will have the information you seek.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜