how to check whether browser is installed on android device
I need to check whether browser is installed on a device or not.how can we do that
You can check whether an intent to go to a web page can be resolved:
public Boolean isBrowserInstalled() {
String url = "https://stackoverflow.com";
Uri webAddress = Uri.parse(url);
Intent intentWeb = new Intent(Intent.ACTION_VIEW, webAddress);
return (intentWeb.resolveActivity(getPackageManager()) != null);
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With