【发布时间】:2019-04-06 18:13:54
【问题描述】:
使用所见即所得编辑器重新排列布局后,出现了问题。我对现有的 TextView 设置了一些新的约束,发现我无法再编译。
Java 编译器显示 failed linking file resources,而问题是 layout_constraintTop_toEndOf' not found.。
我的布局是一个 ConstraintLayout,我的成绩文件有 implementation 'com.android.support.constraint:constraint-layout:1.1.3' 行。
我尝试了Sync Project with Gradle Files、Build -> Clean Project 和Invalidate Caches / Restart,但没有成功。
我真的不知道该说什么了;如果删除约束,我将无法运行代码(我收到元素需要约束的警告),但我无法使用约束集运行代码。
谷歌搜索没有任何用处,看来我可能不得不重新安装并从那里开始,除非其他人遇到了类似的问题。
【问题讨论】:
标签: xml android-studio gradle wysiwyg