uninstall app silently in android? -
I want to delete the device quietly. I'm trying this code, but gives an exception "neither user 10051 nor The current process is android.permission.DELETE_PACKAGES. " It is impossible to program quietly The best you can do is ask the user to delete the app in the dialog. When it presses "OK", there is a guideline on the application given on the Uninstaller application. It is still the user's choice, if he wants to complete the removal operation. User is one way of saying that the user finishes the deleted operation, but it is neither loud nor rigid. After turning off the Uninstaller application, it will return to How to check if an app is installed : If the How to indicate uninstaller for an app : onActivityResult () in your activity. You can see if the app needs to be deleted or not. If it has not been deleted yet, you can return to the same dialog and ask again to delete the application. You can continue in this endless loop until you have prevented the user from deleting the app or using your main application. (I.e. you are telling the user that he can not use your app until he removes the second app.)
last string packagename = "com.company.other-app-name"; Android.content.pm.PackageManager pm = getPackageManager (); PackageInfo info = pm.getPackageInfo (package name, 0);
information == blank or
namedNotFix exception is thrown, the app is not installed.
Uri Uri = Uri.parse ("package: com.company .other-app-name "); Intent to intent = new intent (int. Action_deete, yuri); StartActivityForResult (intent, REQUEST_CODE_UNINSTALL_FREE_APP);
Comments
Post a Comment