Error:(24, 13) Failed to resolve: com.android.support:recyclerview-v7:20.+ <a href="install.m2.repo"

原创 2015年07月07日 10:04:34

Android studio   报错    Error:(24, 13) Failed to resolve: com.android.support:recyclerview-v7:20.+

<a href="install.m2.repo">Install Repository and sync project</a><br><a href="openFile">Show in File</a><br><a href="open.dependency.in.project.structure">Show in Project Structure dialog</a>

   Error:(25, 13) Failed to resolve: com.android.support:leanback-v17:20.+
<a href="install.m2.repo">Install Repository and sync project</a><br><a href="openFile">Show in File</a><br><a href="open.dependency.in.project.structure">Show in Project Structure dialog</a>


点击运行  报
Error:A problem occurred configuring project ':myapplication'.
> Could not resolve all dependencies for configuration ':myapplication:_debugCompile'.
   > Could not find any version that matches com.android.support:recyclerview-v7:20.+.
     Searched in the following locations:
         https://jcenter.bintray.com/com/android/support/recyclerview-v7/maven-metadata.xml
         https://jcenter.bintray.com/com/android/support/recyclerview-v7/
         file:/D:/adt/adt-bundle-windows-x86_64-20140702/sdk/extras/android/m2repository/com/android/support/recyclerview-v7/maven-metadata.xml
         file:/D:/adt/adt-bundle-windows-x86_64-20140702/sdk/extras/google/m2repository/com/android/support/recyclerview-v7/maven-metadata.xml
         file:/D:/adt/adt-bundle-windows-x86_64-20140702/sdk/extras/google/m2repository/com/android/support/recyclerview-v7/
     Required by:
         MyApplication2:myapplication:unspecified
   > Could not find any version that matches com.android.support:leanback-v17:20.+.
     Searched in the following locations:
         https://jcenter.bintray.com/com/android/support/leanback-v17/maven-metadata.xml
         https://jcenter.bintray.com/com/android/support/leanback-v17/
         file:/D:/adt/adt-bundle-windows-x86_64-20140702/sdk/extras/android/m2repository/com/android/support/leanback-v17/maven-metadata.xml
         file:/D:/adt/adt-bundle-windows-x86_64-20140702/sdk/extras/google/m2repository/com/android/support/leanback-v17/maven-metadata.xml
         file:/D:/adt/adt-bundle-windows-x86_64-20140702/sdk/extras/google/m2repository/com/android/support/leanback-v17/
     Required by:
         MyApplication2:myapplication:unspecified


解决方案:
  1. 根据路径  找到 file:/D:/adt/adt-bundle-windows-x86_64-20140702/sdk/extras/android/m2repository/com/android/support/leanback-v17/maven-metadata.xml

  2.打开maven-metadata。xml    
metadata>
  <groupId>com.android.support</groupId>
  <artifactId>recyclerview-v7</artifactId>
  <version>21.0.0</version>
-<versioning>
-<versions>
  <version>21.0.0</version>
  <version>21.0.2</version>
  <version>21.0.3</version>
  <version>22.0.0</version>
  <version>22.1.0</version>
  <version>22.2.0</version>
  </versions>
  <lastUpdated>20150521233210</lastUpdated>
  </versioning>
  </metadata>

3.  可以看到版本号是21+,所以更改  

com.android.support:recyclerview-v7:20.+为

com.android.support:recyclerview-v7:21.+

同理根据上面方法打开
file:/D:/adt/adt-bundle-windows-x86_64-20140702/sdk/extras/android/m2repository/com/android/support/leanback-v17/maven-metadata.xml

<?xml version="1.0" encoding="UTF-8"?>
-<metadata>
  <groupId>com.android.support</groupId>
  <artifactId>leanback-v17</artifactId>
  <version>21.0.0</version>
-<versioning>
-<versions>
  <version>21.0.0</version>
  <version>21.0.2</version>
  <version>21.0.3</version>
  <version>22.0.0</version>
  <version>22.1.0</version>
  <version>22.2.0</version>
  </versions>
  <lastUpdated>20150521233206</lastUpdated>
  </versioning>
  </metadata>
com.android.support:leanback-v17:20.+改为com.android.support:leanback-v17:21.+

Failed to resolve: com.android.support:appcompat-v7:21.的解决方法

在使用Android Studio的时候,有时候编译程序会报以上错误,出现错误的原因是缺少程序运行所需要的兼容库 support Library , 与eclipse每次创建程序都会生成相对应的su...

Android Studio Error:Failed to resolve: com.android.support:appcompat-v7:25.1.0

今天不知道为什么导入eclipse项目后就出现了错误,没导入之前是正常使用AS的 Error:(26, 13) Failed to resolve: com.android.support:appc...

Android studio 2.3.3.0 报错Error:(26, 13) Failed to resolve: com.android.support:appcompat-v7:27.+

Error:Failed to find: com.android.support:appcompat-v7:21.+

最近开始使用Android Studio 出现无法标题的错误,导致无法build 和运行 然后查看android sdk manager发现如图 需要勾上然后 点击安装即可,然后重新编译!...
  • cuiran
  • cuiran
  • 2015年07月13日 14:00
  • 9713

android studio使用说明

一.学习的基本配置文档,搞好各种参数的基本配置,熟练使用。 C:\Program Files\Java\jdk1.7.0_09\bin   二.problems meet...

Android *** android studio Error:Failed to resolve: com.android.support:appcompat-v7:23.+

下午装了android studio,然后新建一个helloworld的project却报了这么一个错误:android studio Error:Failed to resolve: com.and...
  • treeshy
  • treeshy
  • 2016年09月05日 19:41
  • 3797

failed to resolve com.android.support:appcompat-v7:23+ 解决方法

failed to resolve com.android.support:appcompat-v7:23+ 解决方法

Failed to resolve:com.android.support:appcompat-v7:报错处理

你在使用android studio时是否也出现过上图的报错,你还在为它的出现烦恼?没问题,看了本文章,我确保你会顺利解决掉它并会很骄傲的认为这只是一个小case级别的报错。我们进入正题吧,先来说下什...

Failed to resolve:com.android.support:appcompat-v7:报错处理

你在使用android studio时是否也出现过上图的报错,你还在为它的出现烦恼?没问题,看了本文章,我确保你会顺利解决掉它并会很骄傲的认为这只是一个小case级别的报错。我们进入正题吧,先来说下什...

Failed to resolve : com.android.support:appcompat-v7:24.2.0

1 开发环境     Ubuntu14.04(64bit)     Android Studio 2.2.2 2 问题描述     在编译我的第一个项目的时候,提示: 3 解决方法     根据参...
内容举报
返回顶部
收藏助手
不良信息举报
您举报文章:Error:(24, 13) Failed to resolve: com.android.support:recyclerview-v7:20.+ <a href="install.m2.repo"
举报原因:
原因补充:

(最多只允许输入30个字)