I\'m trying my hand and Android Application Development. I\'m currently using Eclipse (I can\'t remember the version, whatever the newest is). I\'ve crossed a bridge where I
I know this is probably a dead thread but just in case someone stumbles upon here having an identical problem - your manifest might be missing the following meta information:
<meta-data
android:name="com.google.android.gms.version"
android:value="@integer/google_play_services_version" />
Declare it within the <application>
element and your code should work. I ran into the same issue following a youtube tutorial that skipped this step and only when carefully going through the original Google tutorial I noticed the missing code.
Anyway, hope this helps someone.
I had a similar error and I think it comes from this point: when I include the Google Play Service API I do not copy it in my workspace, I use the original one !!!
Note: You should be referencing a copy of the library that you copied to your source tree—you should not reference the library from the Android SDK directory.
Check this point.
I have got similar problem that I resolved by right click project->tools>add support library
...
and setup library
I hope this help you
using both meta data references was resolving the issue in my case:
<meta-data
android:name="com.google.android.gms.version"
android:value="@integer/google_play_services_version" />
<meta-data
android:name="com.google.android.maps.v2.API_KEY"
android:value="yourAPIkeyFromGoogleAPIConsole" />
I spend a lot of time trying to solve this problem and after much reading and trying, I solved by changing the
public class MainActivity extends FragmentActivity
for this
public class MainActivity extends android.support.v4.app.FragmentActivity
I hope this can help you
In Some of android 6.0 mobile this exception is bug If unable to flat XML cause by
Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'android.content.res.Configuration android.content.res.Resources.getConfiguration()' on a null object reference
Then it is active bug in android https://issuetracker.google.com/issues/35827842
This can be solved by adding
android:hardwareAccelerated="true" adding in activity tag