Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to get package name of camera application

Tags:

android

Thanks for previous replies,

Is it possible to get Package name of camera application which is installed on the device? If the OS is customized the default package name is changed by the device manufacturer. How can I get the package name through coding ? I am not sure this will be possible.

like image 756
RAAAAM Avatar asked Dec 04 '22 04:12

RAAAAM


1 Answers

Did you try this?

    PackageManager packman = getPackageManager();
    Intent intent = new Intent(MediaStore.ACTION_IMAGE_CAPTURE);
    String pack = intent.resolveActivity(packman).getPackageName();
like image 106
Gaurav Das Avatar answered Dec 05 '22 18:12

Gaurav Das