Skip to content Skip to sidebar Skip to footer

Mapview Crashed In Android Api V2

I tried to create a mapview using android api v2. But my app got crashed in device. But working in emulator not crashing These are the main errors i got. I cant figure out whats th

Solution 1:

Your logcat clearly said

Caused by: java.lang.IllegalStateException: The meta-data tag in your app's AndroidManifest.xml does not have the right value. Caused by: java.lang.IllegalStateException: The meta-data tag in your app's AndroidManifest.xml does not have the right value. Expected 4323000 but found 0. You must have the following declaration within the element: 04-17 14:59:51.881: E/AndroidRuntime(1057): Expected 4323000 but found 0. You must have the following declaration within the element:

Try to add <meta-data> tag under <application> tag in your manifest.xml file like

<meta-data
 android:name="com.google.android.gms.version"
 android:value="@integer/google_play_services_version" />

Make your manifest.xml like this

....<application>
..............
<meta-dataandroid:name="com.google.android.maps.v2.API_KEY"android:value="Key" /><meta-dataandroid:name="com.google.android.gms.version"android:value="@integer/google_play_services_version" /></application>

Post a Comment for "Mapview Crashed In Android Api V2"