我尝试了下面的教程 MapView。
我已经添加了
1) 单声道,Android.Googlemaps。
2)使用Android.Locations;
3)实现:公共类Activity1:MapActivity
这些是错误消息:
错误 CS0115:“MapView.Activity1.IsRouteDisplayed”:找不到合适的方法来覆盖 (CS0115) (MapView)
错误 CS0246:找不到类型或命名空间名称“MapActivity”(您是否缺少 using 指令或程序集引用?) (CS0246) (MapView)
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical">
<com.google.android.maps.MapView
android:id="@+id/map"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:apiKey="my google map key here" />
</LinearLayout>
[Activity (Label = "MapView", MainLauncher = true)]
public class Activity1 : MapActivity
{
protected override void OnCreate (Bundle bundle)
{
base.OnCreate (bundle);
SetContentView (Resource.Layout.Main);
}
protected override bool IsRouteDisplayed
{
get
{
return false;
}
}
}
非常感谢您对此的帮助。
谢谢