2

I am trying to load a map .The map elements like zoom,location etc are loaded however the map isn't displayed

I have added the api key and other stuffs needed for the map.

I get the logcat as :The Google Play services resources were not found. Check your project configuration to ensure that the resources are included.

Below is my manifest Xml

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    package="com.blah.blahh"
    android:versionCode="1"
    android:versionName="1.0" >

     <permission android:name="com.xxx.xxx.permission.MAPS_RECEIVE"
        android:protectionLevel="signature"></permission>

    <uses-sdk
        android:minSdkVersion="8"
        android:targetSdkVersion="17" />


    <uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
    <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
    <uses-permission android:name="android.permission.ACCESS_LOCATION_EXTRA_COMMANDS" />
    <uses-permission android:name="android.permission.ACCESS_MOCK_LOCATION" />
    <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
    <uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
    <uses-permission android:name="android.permission.INTERNET" />
    <uses-permission android:name="android.permission.CHANGE_WIFI_STATE" />
    <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
    <uses-permission android:name="com.google.android.providers.gsf.permission.READ_GSERVICES"/>

    <application
        android:allowBackup="true"
        android:icon="@drawable/ic_launcher"
        android:label="@string/app_name"
        android:theme="@style/AppTheme" >
        <activity
        .
        .
        .

                </activity>

         <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="AIzaXXXxXXXXXXXXXX7mSf-THX" />   

    </application>

</manifest>

Any thoughts regarding this are welcome

Abx
  • 2,702
  • 3
  • 28
  • 49
  • 2
    you have not referenced google play services library project or your device does not have google play services installed – Raghunandan Jan 31 '14 at 11:34
  • Follow the official tutorial from google exactly. – Sherif elKhatib Jan 31 '14 at 11:35
  • @Raghunandan My device has google play services installed – Abx Jan 31 '14 at 11:37
  • 1
    I found the same issue but when i signed my apk then issue is solved – M D Jan 31 '14 at 11:59
  • @MD I had tried a small app only for testing map and it worked.I use the same code in my present app it fails, Any idea about it? – Abx Jan 31 '14 at 12:03
  • 1
    I added poogle play version in my package http://stackoverflow.com/a/21427839/1012284. I think you are trying to get the version from the google-play lib project. Just add the resourse in your project dimen.xml, – Padma Kumar Jan 31 '14 at 12:04
  • 1
    as per my opinion u should remove `google_play_lib library` from u r project and update first and then add this library again and clean built u r project. i m doing same and it's working – M D Jan 31 '14 at 12:05

2 Answers2

3

include this in manifest

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

Please make sure you have added google play store library project with your project.

Also make sure you have added the map api key corresponding to your app signature

Dennis MP
  • 12,084
  • 10
  • 43
  • 61
0

The package name provided to get API key may be changed. Make sure that package name used correct

Arun Antoney
  • 4,072
  • 2
  • 19
  • 25