inflearn logo
강의

강의

N
챌린지

챌린지

멘토링

멘토링

N
클립

클립

로드맵

로드맵

지식공유

라즈판다님의 게시글

라즈판다 라즈판다

@raspberrypanda

수강평 작성수
-
평균평점
-

게시글 1

질문&답변

<LinearLayout>에 에러가 발생합니다..

코드는 그대로 입력했는데 실행이 안됩니다. 코드들은 아래와 같습니다. [.kt 파일] package com.example.bst_app import androidx.appcompat.app.AppCompatActivity import android.os.Bundle import android.widget.Toast import kotlinx.android.synthetic.main.activity_main.* class MainActivity : AppCompatActivity() { override fun onCreate (savedInstanceState: Bundle?) { super .onCreate(savedInstanceState) setContentView(R.layout. activity_main ) button_one_name.setOnClickListener { Toast.makeText( this, " 토스트입니다 ." , Toast. LENGTH_LONG ).show() } } } [.xml 파일] xml version ="1.0" encoding ="utf-8" ?> 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" android :orientation ="vertical" tools :context =".MainActivity" > android :id ="@+id/button_one_name" android :layout_width ="wrap_content" android :layout_height ="wrap_content" android :text =" 정국 " /> android :layout_width ="wrap_content" android :layout_height ="wrap_content" android :text =" 슈가 " /> android :layout_width ="wrap_content" android :layout_height ="wrap_content" android :text =" 제이홉 " /> android :layout_width ="wrap_content" android :layout_height ="wrap_content" android :text =" 뷔 " /> android :layout_width ="wrap_content" android :layout_height ="wrap_content" android :text =" 진 " /> android :layout_width ="wrap_content" android :layout_height ="wrap_content" android :text =" 지민 " /> android :layout_width ="wrap_content" android :layout_height ="wrap_content" android :text ="RM" /> [AVD 설정] [실행화면] [오류내용] 왜 안되는 건가요... ㅠㅜ

좋아요수
1
댓글수
4
조회수
963