programmatically uninstall other application without asking user

2.2k views Asked by At

I have system-level app with

Device is not rooted! INSTALL_PACKAGES and ACTION_UNINSTALL_PACKAGE permission is included to Manifest

Can I install and Uninstall any apk silently ?

1

There are 1 answers

2
Amsheer On

I don't think you can uninstall app without user confirmation

But uninstall app use the following code.

Intent intent = new Intent(Intent.ACTION_DELETE);
                    intent.setData(Uri.parse("package:com.example.getgoogleaccount"));
                    startActivity(intent);