EDIT :
I transferred my 20+ projects that tries to use Google Maps for Android v2. After changing keys and stuff, now, it works. I don't know what made this work, but thank you all. I got one keystore, the key is right. I guess it magically fixed somehow. Well, thanks guys.
I'm doing searches for 2 days and I couldn't fix this problem. I did everything, yet, this application can not work.
I want my application to work on Android 2.2 and above. Like it says "if you create your app in level 8, it'll support 95% of market".
Here are my screenshots and source codes:
I'm pasting the source code which is the easiest to get. I took this from web.
Here's the output of the command
keytool -list -keystore <path>
***************** WARNING WARNING WARNING ***************** * The integrity of the information stored in your keystore * * has NOT been verified! In order to verify its integrity, * * you must provide your keystore password. * ***************** WARNING WARNING WARNING *****************
Keystore type: JKS Keystore provider: SUN
Your keystore contains 1 entry
androiddebugkey, 15.Mar.2013, PrivateKeyEntry,
Certificate fingerprint (SHA1): xxx
main.xml file:
<?xml version="1.0" encoding="utf-8"?>
<com.google.android.maps.MapView
xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/mapView"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:clickable="true"
android:apiKey="AIzaSyDim-x5Gxxx"
/>
manifest file:
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.androidhive.googlemaps"
android:versionCode="1"
android:versionName="1.0" >
<uses-sdk android:minSdkVersion="8" />
<application
android:icon="@drawable/ic_launcher"
android:label="@string/app_name" >
<!-- Add Google Map Library -->
<uses-library android:name="com.google.android.maps" />
<activity
android:name=".AndroidGoogleMapsActivity"
android:label="@string/app_name" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
<!-- Allow to connect with internet -->
<uses-permission android:name="android.permission.INTERNET" />
</manifest>
java file (no need to paste it all, but I guess it's best to paste it all)
Here are my screenshots:
http://i.imgur.com/gExHpUG.png
http://i.imgur.com/AMOXKhr.png
http://i.imgur.com/Aqon97Y.png
I'm trying to compile this app to Android 4.2.2, but I tried and want to make it work in 2.2 and above.
Here's the Android tab of the properties window just to make sure:
http://i.imgur.com/ht0CQwT.png
Here's my log
03-20 07:01:20.145: W/System.err(956): at java.lang.Thread.run(Thread.java:856)
03-20 07:01:20.665: W/System.err(956): IOException processing: 26
03-20 07:01:20.665: W/System.err(956): java.io.IOException: Server returned: 3
03-20 07:01:20.665: W/System.err(956): at android_maps_conflict_avoidance.com.google.googlenav.map.BaseTileRequest.readResponseData(BaseTileRequest.java:115)
03-20 07:01:20.675: W/System.err(956): at android_maps_conflict_avoidance.com.google.googlenav.map.MapService$MapTileRequest.readResponseData(MapService.java:1473)
03-20 07:01:20.675: W/System.err(956): at android_maps_conflict_avoidance.com.google.googlenav.datarequest.DataRequestDispatcher.processDataRequest(DataRequestDispatcher.java:1117)
03-20 07:01:20.675: W/System.err(956): at android_maps_conflict_avoidance.com.google.googlenav.datarequest.DataRequestDispatcher.serviceRequests(DataRequestDispatcher.java:994)
03-20 07:01:20.675: W/System.err(956): at android_maps_conflict_avoidance.com.google.googlenav.datarequest.DataRequestDispatcher$DispatcherServer.run(DataRequestDispatcher.java:1702)
These lines repeat all the time.
Thank you very much. Your post appears to contain code that is not properly formatted as code" error made me delete the blank lines. Sorry for the messed up codes.
http://i.imgur.com/ht0CQwT.png See the snapshot. You did not add Google Play Services library that is require for displaying Google Android Map V2. Please download and add that library and then try again.
Please also see the target. Your target is 4.2.2 and your are accessing it on 2.2. Change the target to 2.2 and use support fragment.
Thanks,
You are missing permissions and meta-data for API KEY.
Read this carefully: https://developers.google.com/maps/documentation/android/start
Working with android mapapi v2 ,the main reason is you must add play service to your app,like below :
Use fragment class in Layout:
And change your manifest:
in activity:
For more info check the link which will explain you in details about api v2
I solved my blank screen problem with zoom in/out buttons like that.(it happens after I changed my package name)
That worked for me
I have solved this issue,