inflearn logo
강의

강의

N
챌린지

챌린지

멘토링

멘토링

N
클립

클립

로드맵

로드맵

지식공유

[왕초보편] 앱 8개를 만들면서 배우는 안드로이드 코틀린(Android Kotlin)

D-Day 앱 만들어보기

D-DAY 카운팅 앱을 만드는 도중에 에러가 레이아웃 파일에서 에러가 발생했습니다.

260

이장한

작성한 질문수 14

0

아래는 코드입니다. 참고로 activity_main 파일입니다.

 

<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".MainActivity">

<TextView
android:id="@+id/textView"
android:layout_width="match_parent"
android:layout_height="wrap_parent"
android:gravity="center"
android:text="D-day Counter"
android:textSize="20sp"
android:textStyle="bold"
app:layout_constraintTop_toTopOf="parent"
/>

<ImageView
android:id="@+id/imageView6"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginTop="50dp"
android:scaleType="fitXY"
android:src="@drawable/tt"
app:layout_constraintBottom_toBottomOf="parent" />


<TextView
android:id="@+id/finaldate"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="0"
android:textColor="@color/black"
android:textSize="50dp"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="@+id/textView" />

<Button
android:id="@+id/startbtn"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_margin="20dp"
android:text="시작일"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintStart_toStartOf="parent" />

<Button
android:id="@+id/endbtn"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_margin="20dp"
android:text="시작일"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent" />
</androidx.constraintlayout.widget.ConstraintLayout>


//이런 식으로 코딩을 했는데
//18번째줄에 android resource linking failed 이라는 오류가 발생했습니다.
//해결 방법이 궁금합니다. 항상 감사드립니다!!

 

kotlin android firebase

답변 2

0

개복치개발자

drawable 폴더 포함 모든 프로젝트 구조를 스크린샷으로 공유해주시겠어요?

0

이장한

앗 이미지 이름 관련해서 수정을 했더니 해결이 되었습니다 감사합니다!!

 

0

개복치개발자

혹시 drawable 폴더에

android:src="@drawable/tt"

tt라는 이미지가 있나요?

0

이장한

예 있습니다!!

 

주사위앱 소개 및 레이아웃 설정 문제

0

81

2

안드로이드 에뮬레이터가 실행이 안 되요...ㅠ

0

141

2

30 강 소스 좀 올려 주십시요

0

97

2

onBackPressed 함수가 동영상 하고 다르게 동작합니다.

0

108

2

ListView 초기 실행 안됩니다.

0

110

2

코딩을 완료하고난후 앱 실행시 자동 종료

0

87

2

datavinding에서 오류가 납니다.

0

64

1

안드로이드 스튜디오 버전 차이로 초기 empyt activity 선택하면 안됩니다.

0

138

2

context의 구별에 대하여

0

86

2

"프롤로그에서 ..." 오류 관련해 직전 질문에 대한 추가 질문입니다.

0

80

2

"프롤로그에서 콘텐츠가 허용되지 않습니다." 오류

0

187

3

해결완료

1

205

2

databinding 설정후 run하면 에러(해결)

0

234

2

databinding 설정 이후 실행시 에러

0

297

4

안드로이드 입문하는 사람입니다.

0

78

1

Firebase uid

0

90

3

activity_main 화면 다름

0

129

2

강의화면과 다른데 맞게진행되는것인가요...????

0

117

2

파이어베이스 질문

0

84

2

ActivityMainBinding에 오류가 납니다

0

146

2

선생님 onBackPressed 작동이 안되는거 같습니다

0

128

2

>app>res>layout 이 존재하지 않습니다.

0

124

2

안드로이드 스튜디오 미어캣 버전 사용 한글 깨짐

0

784

2

안드로이드 스튜디오 오류 발생 시 대처 방법은 요?

0

310

2