今天在导入项目的时候报错:

Error:Could not find com.android.support.constraint:constraint-layout:1.0.0-alpha7.

导入项目的时候报错Error:Could not find com.android.support.constraint:constraint-layout:1.0.0-alpha7

原因是:没有下载相应版本的ConstraintLayout。

解决方案

工具栏上选择 Tools --> Android -->SDK Manager 

导入项目的时候报错Error:Could not find com.android.support.constraint:constraint-layout:1.0.0-alpha7

切换到SDK Tools选项,在右下角处勾选 Show Package Details

 导入项目的时候报错Error:Could not find com.android.support.constraint:constraint-layout:1.0.0-alpha7

Support Repository下的ConstraintLayout for Android 和 Solver for ConstraintLayout 中选中自己需要的版本(gradle中依赖的版本)

导入项目的时候报错Error:Could not find com.android.support.constraint:constraint-layout:1.0.0-alpha7

点OK进行下载

 导入项目的时候报错Error:Could not find com.android.support.constraint:constraint-layout:1.0.0-alpha7

导入项目的时候报错Error:Could not find com.android.support.constraint:constraint-layout:1.0.0-alpha7

再同步gradle就可以了

 导入项目的时候报错Error:Could not find com.android.support.constraint:constraint-layout:1.0.0-alpha7

参考资料

依赖ConstraintLayout报错,Could not find *****,Failed to resolve:*****

 

相关文章:

  • 2021-10-25
  • 2021-06-12
  • 2021-06-05
  • 2021-04-18
  • 2021-05-24
  • 2021-05-06
  • 2022-12-23
  • 2022-01-31
猜你喜欢
  • 2021-12-22
  • 2021-06-01
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-09-25
  • 2021-04-28
相关资源
相似解决方案