Menu
Tag

Android

Android Error: Failed to resolve: com.google.firebase

[Android Studio] Issue: I updated gradle to 4.4 in my Android app and added below firebase libraries to my app level build.gradle file implementation ‘com.google.firebase:firebase-core:16.0.0’ but while building the project, got the below error Failed to resolve: com.google.firebase:firebase-core:16.0.0 Solution: This is a maven issue. This issue is resolved after adding google() to repositories of allporjects in project level build.gradle file. Now…

Error:The number of method references in a .dex file cannot exceed 64K. Learn how to resolve this issue at https://developer.android.com/tools/building/multidex.html

While building an android app in Android Studio, I got the below error and the build was failed.Error: The number of method references in a .dex file cannot exceed 64K. Learn how to resolve this issue at https://developer.android.com/tools/building/multidex.html The solution to avoid this error is, add the property “multiDexEnabled true” under defaultConfig in app’s build.graddle file. It will look like below….

WindowManager: android.view.WindowLeaked: Activity has leaked window

While developing an android mobile app, I received this error. In the mobile app, on click of back button, a dialog will be opened with few buttons including “Exit”. On click of exit, I have given (Activity context).finish(); but it is throwing the below error.WindowManager: android.view.WindowLeaked: Activity <app package> has leaked window com.android.internal.policy.impl.PhoneWindow$DecorView{45500950 V.E….. R……. 0,0-640,929} that was originally added here…

Run Android Apps on your Mac or PC

Do you have Chrome on your Mac or PC? Then you can run android apps on your Mac or PC. Google has come up with App Runtime for Chrome (ARC).Pre-requisites: You need Chrome browser for sure to start with it apk file of the app  you wanted to install Procedure: Below is the procedure to setup and install the apk file….

AlarmManager – run any code in the background at certain intervals

If you want to run a piece of code in the background at certain intervals, then AlarmManager is the class helps us to do this. It will wake up the device on the given intervals and invokes the Receiver class where we should write our code to run in the background. Below code snippet explains how to implement AlarmManager. Intent…

android.os.NetworkOnMainThreadException

android.os.NetworkOnMainThreadException  is an android runtime exception which occurs when you are trying to run any network or IO related operations from main activity. Android doesn’t support to run IO operations directly on the main activity. So to avoid this exception, use a thread to do these operations or you can also use AsyncTask class which helps you to run the…

android.content.ActivityNotFoundException: Unable to find explicit activity class

I am developing an android application. On the home screen, it has a button, on click of this an activity should be displayed. While testing the app, on click of the button, the app is giving the below error and the app got terminated.E/AndroidRuntime(Number): java.lang.RuntimeException: Unable to resume activity {app package}: android.content.ActivityNotFoundException: Unable to find explicit activity class {activity class};…

Hi, Welcome here.
JOIN OUR NEWSLETTER
And get notified everytime we publish a new blog post.