android - 如何在已签名的 Android 应用程序上获取 map ?

标签 android map

我已经创建了一个 map 应用程序。它在没有签署 APK 的情况下显示 map ,但是当我尝试签署并稍后在设备中安装该 APK 时, map 不再显示。

最佳答案

您需要单独的 Google Maps API key 才能发布。你说你在 APK 工作时没有签署它,但应用程序实际上是由你的 SDK 使用调试 key 自动签署的。您也可能拥有有效的 Google Maps API key 。

来自 https://code.google.com/android/add-ons/google-apis/mapkey.html 处的文档:

While you are developing and debugging your application, you will likely be sigining your application in debug mode — that is, the SDK build tools will automatically sign your application using the debug certificate. To let your MapView elements properly display Maps data during this period, you should obtain a temporary Maps API Key registered to the debug certificate. To do so, you first need to get the MD5 fingerprint of the debug certificate. When you are ready to release your application, you must register your release certificate with the Google Maps service and obtain a new Maps API Key. You must then change the MapView elements in your application to reference the new API key.

关于android - 如何在已签名的 Android 应用程序上获取 map ?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/5217139/

相关文章:

map - 提取失败太多

java - 树的分区压缩以及如何将节点压缩到根

Android - 为 map 或图片设计数据库?

android - ionic 2错误中的本地存储

android - OnClickListener 不响应 fragment 中的点击

android - 机器人 : How to get button id from onClick method described in XML?

android - 返回到具有自定义 View 的 Activity 时,Invalidate 无法调用 onDraw

java - Android - 将 Map<String, Object[]> 保存到文件

objective-c - 经纬度中点到直线的最小距离

c++ - C++ 中混合类型的容器(类似于 nsdictionary)