마스터Q&A 안드로이드는 안드로이드 개발자들의 질문과 답변을 위한 지식 커뮤니티 사이트입니다. 안드로이드펍에서 운영하고 있습니다. [사용법, 운영진]

안드로이드스튜디오에서 다음맵 띄우려는데 뭐가문제일까요 ㅠㅠ [closed]

0 추천

//java

package org.androidtown.longfactory;

import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.view.ViewGroup;

import net.daum.mf.map.api.MapView;

public class MainActivity extends AppCompatActivity {
    private MapView mapView;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);

        mapView = (MapView) findViewById(R.id.map_view);

        mapView = new MapView(this);
        mapView.setDaumMapApiKey("ef2c45352e8bf8d416fb8509028ab470");
        ViewGroup mapViewContainer = (ViewGroup) findViewById(R.id.map_view);
        mapViewContainer.addView(mapView);


    }

    

}

//XML

<?xml version="1.0" encoding="utf-8"?>
<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"
    tools:context="org.androidtown.longfactory.MainActivity">

    <LinearLayout
        android:id="@+id/map_view"
        android:orientation="vertical"
        android:layout_width="match_parent"
        android:layout_height="match_parent"/>



</RelativeLayout>

다음API 예제 참고하여 했는데 실행하면은 종료가 되어버리네요

Project Strucure에서도 JAR 라이브러리 다 추가해놓았는데도 안되네요

이제시작한 초보자라서 원인도 잘모르겠어요 도움 부탁드릴게요 ㅠㅠ

질문을 종료한 이유: 나홀로해결
꾸밈 (160 포인트) 님이 2016년 2월 1일 질문
꾸밈님이 2016년 2월 1일 closed
저 이문제 때문에 고민인데 어떻게 해결하셨나요?
...