首页 > 技术文章 > Could not find com.android.support.constraint:constraint-layout的问题解决

freemobile 2018-07-26 11:08 原文

这几天使用android studio的各种坑之一:

Error:Could not find com.android.support.constraint:constraint-layout:1.0.2.
Required by:
project :mvp
<a href="searchInBuildFiles">Search in build.gradle files</a>

 

在于没有按照上的sdk中的constraint-layout,打开file->settings,找打android sdk项里的sdk tools,点击右下角的“Show Package Details”,然后找到Support Repository项,在下面的ContraintLayout for android和Solver for ConstraintLayout中选中版本1.0.2进行安装。 

推荐阅读