问题描述
error: Error: No resource found that matches the given name (at ‘layout_constraintRight_toLeftOf’ with value ‘@id/total_time_tv’).
提示是资源的ID无法引用
解决方式
将声明@+id/view_id
的控件
放置在引用他的控件之前
例如:
<!--先声明-->
<TextView
android:id="@+id/tv_id"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
<!--再引用-->
<TextView
app:layout_constraintTop_toBottomOf="@id/tv_id"
android:id="@+id/tv_id"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />