android mapview not working

…衆ロ難τιáo~ 提交于 2019-12-05 07:22:47

问题


This is killing me!!!

I seem to have done all I need to do but it just wont work!

here is what i did:

-created a keystore using keytool:

$ keytool -genkey -v -keystore PADReleaseKey.keystore -alias pocket_aces_release -keyalg RSA -keysize 2048 -validity 10000

-got the MD5 fingerpring from it and used:

$ keytool -list -alias pocket_aces_release PADReleaseKey.keystore

-used it to get the mapAPI key and embedded it inside my application:

<com.google.android.maps.MapView
    android:layout_weight="1" android:id="@+id/mapview"
    android:layout_width="fill_parent" android:layout_height="fill_parent"
    android:apiKey="0qLwM2TNe70Ho-Y1wZiN2MqF_jFIXLc-0gwLRsw"        
    android:clickable="true"/>

  • exported a signed application package using eclipse and the keystore and alias I have created before.

  • installed it on my android machine using adb install.

but still no map is showing!!!! I have done this several times, but it does not work...

can anyone point me to what am i doing wrong?

Thanks.


回答1:


When you say "no map is showing" could you elaborate on that a little more? Are you seeing a load of grey blank squares? If so thats normally an issue with your API key.

Also are you running it on an emulator that has the Google APIs target? I wrote a really basic guide on getting maps working, it may help you.

Regards



来源:https://stackoverflow.com/questions/4924591/android-mapview-not-working

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!