Bạn đang xem bản rút gọn của tài liệu. Xem và tải ngay bản đầy đủ của tài liệu tại đây (115.83 KB, 3 trang )
Trung tâm Tin học – ĐH KHTN
Cập nhật vị trí của bạn trên bản đồ
Project:
Project name: TestNg22Th11
Build Target: Android 2.3.3 Google APIs
Application name: TestNg22Th11
Package name: com.dac
Create Activity: TestNg22Th11Activity
File main:
<LinearLayout xmlns:android=" /> android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical" >
<com.google.android.maps.MapView
android:id="@+id/MapView"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:clickable="true"
android:apiKey="MAP KEYS"
/>
</LinearLayout>
File Activity:
package com.dac;
import android.os.Bundle;
import com.google.android.maps.*;
public class TestNg22Th11Activity extends MapActivity {
MapView mv;
MyLocationOverlay myOverlay;
GeoPoint pt;
/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState) {