欢迎光临
我们一直在努力

Android 开发相关错误锦集

错误一:

Android resource linking failed
Output: 
E:\ASWorkSpace\SortFileBySize\app\src\main\res\layout\activity_main.xml:13: error: attribute layout_constraintBottom_toBottomOf (aka com.hp.sortfilebysize:layout_constraintBottom_toBottomOf) not found.
E:\ASWorkSpace\SortFileBySize\app\src\main\res\layout\activity_main.xml:13: error: attribute layout_constraintLeft_toLeftOf (aka com.hp.sortfilebysize:layout_constraintLeft_toLeftOf) not found.
E:\ASWorkSpace\SortFileBySize\app\src\main\res\layout\activity_main.xml:13: error: attribute layout_constraintRight_toRightOf (aka com.hp.sortfilebysize:layout_constraintRight_toRightOf) not found.
E:\ASWorkSpace\SortFileBySize\app\src\main\res\layout\activity_main.xml:13: error: attribute layout_constraintTop_toTopOf (aka com.hp.sortfilebysize:layout_constraintTop_toTopOf) not found.
error: failed linking file resources.
Command: C:\Users\tangdekun\.gradle\caches\transforms-1\files-1.1\aapt2-3.2.0-beta03-4818971-windows.jar\868db5e9c484c628dee78cdbe6877651\aapt2-3.2.0-beta03-4818971-windows\aapt2.exe link -I\
  N:\ProgramFiles\android\sdk\platforms\android-28\android.jar\
  --manifest\
  E:\ASWorkSpace\SortFileBySize\app\build\intermediates\merged_manifests\debug\processDebugManifest\merged\AndroidManifest.xml\
  -o\
  E:\ASWorkSpace\SortFileBySize\app\build\intermediates\processed_res\debug\processDebugResources\out\resources-debug.ap_\
  -R\
  @E:\ASWorkSpace\SortFileBySize\app\build\intermediates\incremental\processDebugResources\resources-list-for-resources-debug.ap_.txt\
  --auto-add-overlay\
  --java\
  E:\ASWorkSpace\SortFileBySize\app\build\generated\not_namespaced_r_class_sources\debug\processDebugResources\r\
  --custom-package\
  com.hp.sortfilebysize\
  -0\
  apk\
  --output-text-symbols\
  E:\ASWorkSpace\SortFileBySize\app\build\intermediates\symbols\debug\R.txt\ --no-version-vectors
Daemon:  AAPT2 aapt2-3.2.0-beta03-4818971-windows Daemon #0

错误分析:原因是因为缺少依赖包导致

解决方案:加入下方依赖即可

implementation 'androidx.constraintlayout:constraintlayout:1.1.2'

错误二:

赞(0) 打赏
未经允许不得转载:卧龙岗 » Android 开发相关错误锦集
分享到: 更多 (0)

相关推荐

  • 暂无文章

评论 抢沙发

评论前必须登录!

 

觉得文章有用就打赏一下文章作者

支付宝扫一扫打赏

微信扫一扫打赏