我的谷歌地图为什么无法显示啊啊啊啊!!!
这个如此简单的谷歌地图为什么无法正常显示啊,急!MainActivity.java
package com.wei.mymap;
import android.os.Bundle;
import android.app.Activity;
import android.view.Menu;
import com.google.android.maps.MapActivity;
public class MainActivity extends MapActivity {
/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
}
@Override
protected boolean isRouteDisplayed() {
// TODO Auto-generated method stub
return false;
}
}
activity_main.xml文件
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent" >
<com.google.android.maps.MapView
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:enabled="true"
android:clickable="true"
android:apiKey="AIzaSyC_UPoZZcnZNiUo2otFdfQERP-lOhpOgxQ"
/>
</RelativeLayout>
AndroidMainfest.xml文件
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.wei.mymap"
android:versionCode="1"
android:versionName="1.0" >
<uses-sdk
android:minSdkVersion="8"
android:targetSdkVersion="15" />
<uses-permission android:name="android.permission.INTERNET"/>
<application
android:icon="@drawable/ic_launcher"
android:label="@string/app_name"
android:theme="@style/AppTheme" >
<activity
android:name=".MainActivity"
android:label="@string/title_activity_main" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<uses-library android:name="com.google.android.maps" />
</application>
</manifest>
我保证我的虚拟机能正常显示,用的也是API,还有那个key也能正常使用!
但是就是不显示,为啥啊?
--------------------编程问答-------------------- android:apiKey="AIzaSyC_UPoZZcnZNiUo2otFdfQERP-lOhpOgxQ" 自己申请的么 --------------------编程问答-------------------- 是不是Google的服务器被墙了呢? --------------------编程问答-------------------- 补充一楼:每个APIKey对应一台电脑,注意 --------------------编程问答-------------------- 服务器不稳定 --------------------编程问答-------------------- Google地图不稳定,以前我用好好的, 现在显示不出来。 --------------------编程问答--------------------
是啊,自己申请的 --------------------编程问答--------------------
不可能吧,为什么能用在网页上,安卓应用用不了 --------------------编程问答--------------------
我同学的也是,但是,为什么网页能用? --------------------编程问答-------------------- 最近网络美国网络有异常,万恶的资本主义啊.
补充:移动开发 , Android