Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Could not determine the installation package com.company.appName

I can't launch my app anymore on Android. The iOS counterpart seems to be fine. The full error is:

ADB0000: Could not determin the installation path for package.com.company.appname. 
'adb shell pm path com.company.appname' returned.

It was working. I pulled some changes from the repo, none of which should have affected any app properties. Actually it was initially launching, but I was getting some odd behavior within the app, so I uninstalled the whole thing off of my phone. Now I cannot launch it at all. What I could find about this error was that my AndroidManifest.xml might have a typo, but I couldn't find anything that stuck out. And like I said, there shouldn't have been any changes in there recently. Any help would be greatly appreciated.

Steps I have already taken: 1. Clean and rebuild 2. restart VS 3. delete obj and bin folders 4. search for solution on here and xamarin forums

UPDATE: I just successfully launched it on another android device. So it seems to be a problem with my Pixel 2 XL. How do I make sure all traces of the app are gone so I can start fresh?

like image 943
Alex Estrada Avatar asked Jan 17 '19 22:01

Alex Estrada


2 Answers

This usually happens when you have more than one user in an Android device (I still cannot figure out why is this).

As mentioned in the comment by using the adb uninstall full.package.name command it will uninstall the app.

But there's another way which does not require command line or nothing related to that.

If you go to the Settings -> Apps and Notifications on the Android device you will be able to uninstall it from there.

Let's use the UnoQuickStart.Droid app as example here. As you can see it's already in the same state as it was yours.

enter image description here

Once in the App details both Uninstall and Force Stop are disabled. But do you see those 3 dots image at the right upper corner? Click on it.

enter image description here

This will bring you a context menu with a single option "Uninstall for all users". You can click on it with confidence.

enter image description here

As expected, a warning message telling you what's gonna happen. Just click "Ok".

enter image description here

As you can see the App is not longer installed and you will now be able to install it again.

enter image description here

Hope this helps.-

like image 128
pinedax Avatar answered Sep 29 '22 11:09

pinedax


As per apineda's instructions, using adb unistall com.company.appname fixed the problem. I was able to get to the ADB location by navigating through Visual Studio -> Tools -> Android -> Android ADB Command Prompt.

Before I did that, I looked at the App list for my phone, which listed the app, but apparently not installed for this user. The Uninstall and Force Stop buttons were disabled and several of the fields just said loading... or something like that.

like image 43
Alex Estrada Avatar answered Sep 29 '22 13:09

Alex Estrada