java - Blank screen on application while using Google Map API v2 -
could not find class com.google.android.gms.location.internal.parcelablegeofence, referenced method gls.a
is error getting. tried changing api key well, still same blank screen.
these our xml files:
<?xml version="1.0" encoding="utf-8"?> <manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.example.khanakhazana" android:versioncode="1" android:versionname="1.0" > <uses-sdk android:minsdkversion="11" android:targetsdkversion="19" /> <uses-permission android:name="android.permission.internet"/> <uses-permission android:name="android.permission.access_network_state"/> <uses-permission android:name="android.permission.write_external_storage"/> <uses-permission android:name="com.google.android.providers.gsf.permission.read_gservices"/> <!-- following 2 permissions not required, recommended. --> <uses-permission android:name="android.permission.access_coarse_location"/> <uses-permission android:name="android.permission.access_fine_location"/> <permission android:name="com.example.khanakhazana.permission.maps_receive" android:protectionlevel="signature" /> <uses-permission android:name="com.example.khanakhazana.permission.maps_receive" /> <uses-feature android:glesversion="0x00020000" android:required="true" /> <uses-permission android:name="android.permission.write_external_storage" /> <uses-permission android:name="android.permission.access_network_state" /> <application android:allowbackup="true" android:icon="@drawable/ic_launcher" android:label="@string/app_name" android:theme="@style/apptheme" > <activity android:name=".mainactivity" android:label="@string/app_name" android:screenorientation="portrait" > <intent-filter> <action android:name="android.intent.action.main" /> <category android:name="android.intent.category.launcher" /> </intent-filter> </activity> <activity android:name=".restaurants" android:label="@string/title_activity_restaurants" > </activity> <activity android:name=".info" android:label="@string/title_activity_info" > </activity> <activity android:name=".map" android:label="@string/title_activity_map" > </activity> <activity android:name=".notify" android:label="@string/title_activity_notify" > </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="aizasyc5yxqw5gwvwvr7clnl4fvvp0pc6mo1oy4" /> </application> </manifest>
and:
<?xml version="1.0" encoding="utf-8"?> <relativelayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="fill_parent" > <fragment android:id="@+id/map" android:name="com.google.android.gms.maps.supportmapfragment" android:layout_width="match_parent" android:layout_height="match_parent"/> </relativelayout>
as per understanding issue happening because of 3 reason
reasons
1) first lack of internet connectivity
2) second google api key missmatching
3) third if key ok provided package name during key generation not exact same project package name
solutions
for first need check internet conncetion working or not need go further
for second , third need create key proper steps if using eclipse then
eclipse-->windows-->preferences-->android-->build sha key
use sha key generate android key
after pasting sha key append project package name following symbol ";"
for example
yor_sha_key;your_project_main_package_name generate key google map key android use 1 hope resolve problem make sure using same pakcage name project package name
hope solve problem happy coding :)
Comments
Post a Comment