0

Hi I am developing simple android application in which I am using android mapV2. So on Google API console I created one project after than I created new key for my application. So my application manifest looks like :

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

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

    <uses-permission android:name="com.example.maptestapp.permission.MAPS_RECEIVE" />

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

    <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
    <uses-permission android:name="android.permission.INTERNET" />
    <uses-permission android:name="com.google.android.providers.gsf.permission.READ_GSERVICES" />
    <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />

    <!-- Required to show current location -->
    <uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
    <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />

    <!-- Required OpenGL ES 2.0. for Maps V2 -->
    <uses-feature
    android:glEsVersion="0x00020000"
    android:required="true" />

    <application
    android:allowBackup="true"
    android:icon="@drawable/ic_launcher"
    android:label="@string/app_name">
    <activity
        android:name="com.example.maptestapp.MainActivity"
        android:label="@string/app_name"
        android:theme="@style/AppBaseTheme">
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />

            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
    </activity>

    <!-- Goolge API Key -->
    <meta-data
        android:name="com.google.android.maps.v2.API_KEY"
        android:value="AIzaSyC7945EdDYMoMHZAYNvNXbVSl1NSZrWCfs" />
    </application>

</manifest>

So I am defining permissions and also defined meta data. and In layout I am trying to display

<fragment
    android:id="@+id/map"
    android:name="com.google.android.gms.maps.MapFragment"
    android:layout_width="match_parent"
    android:layout_height="match_parent"/>

Now I tried to display my activity it shows me following error :

12-24 22:59:54.345: E/Google Maps Android API(28739): Authorization failure.  Please see https://developers.google.com/maps/documentation/android/start for how to correctly set up the map.
12-24 22:59:54.345: E/Google Maps Android API(28739): Ensure that the following correspond to what is in the API Console: Package Name: com.example.maptestapp, API Key: AIzaSyZAYNvNXbVSl1NSZrWCfs, Certificate Fingerprint: 096388A528A6F8347914D

Its not rendering any map view. Need help. Thank you.

2
  • LogCat is your friend. No need for any answers here. Commented Dec 24, 2013 at 17:44
  • yeah but i checked all things but its not working :( Commented Dec 24, 2013 at 18:18

2 Answers 2

1

please try the link below which show step by step description ,which show how to use google map v2.Try this

Sign up to request clarification or add additional context in comments.

Comments

0

Your API key is wrong. The error explains exactly what you need to do:

Please see https://developers.google.com/maps/documentation/android/start for how to correctly set up the map.

Ensure that the following correspond to what is in the API Console: Package Name: com.example.maptestapp, API Key: AIzaSyZAYNvNXbVSl1NSZrWCfs, Certificate Fingerprint: 096388A528A6F8347914D

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.