I apologize if this has been asked before, I tried searching for it and didn’t find any relevant answers.
I would like my app to determine if Google maps navigation and street view are installed on the phone. If they are allow the user to open them from my app.(I’ve done this without an issue.) Next I would like the app to not allow the user to attempt to open these apps if they are not installed, since it will force close if they are not installed and the user tries to open them. Has anyone dealt with this before?
Sure. First you need to get the list of apps on the phone, like this
Now that you have a list, you can figure out the package names of those apps, and walk the list. If they exist, disable the button/menu option to launch them (for a button, set its visibility to INVISIBLE or GONE. For a menu item, disable it or remove it in the prepare function).