Android studio开发中遇到的一些异常

来源:互联网 发布:sq数据库认证有哪些 编辑:程序博客网 时间:2024/06/05 07:46

1、Gradle: A problem occurred configuring project

Weird error message:

?View Code ERROR
123456
Gradle: A problem occurred configuring project ':App'.> Failed to notify project evaluation listener.   > Could not resolve all dependencies for configuration ':App:_DefaultFlavorDebugCompile'.      > Could not find any version that matches com.android.support:appcompat-v7:+.        Required by:            MyApplication:App:unspecified

If this happens, just go to Tools -> Android -> Android SDK Manager, then check “Android Support Repository” and “Android Support Library” under “Extra” and install them. That should take care of the error.


2、Warning:Gradle version 2.10 is required. Current version is 2.8. If using the gradle wrapper, try editing the distributionUrl in C:\Users\blahblah\myproject\gradle\wrapper\gradle-wrapper.properties to gradle-2.10-all.zip


  1. Go "File" and click "Project structure".

  2. Opening project structure settings for the project

  3. Then select "Project" from left menu and then change "Gradle version" to the version your sdk manager has installed. In my case it is 2.10 so i change version to 2.10 and then click on "Ok". And then android studio automatically do gradle sync again and error was fixed.Changing gradle version to the latest installed version for the project



0 0
原创粉丝点击