Programmer algorithm practice must read, common Java API skills to share>>>
The solution is as follows
The first is the simplest, but it is not recommended
In build. Gradle
classpath'com.android.tools.build:gradle:2.0.0-alpha9'
Change to
classpath'com.android.tools.build:gradle:1.5.0'
Or
classpath'com.android.tools.build:gradle:1.3.0'
This method is not recommended, but it is simple and feasible
Second, this is the right way to solve the problem
Download first
https://services.gradle.org/distributions/gradle-2.10-all.zip
Of course, if there are new ones, you can also download them. If you don’t know the download address, studio will remind you
Then open the path
\android-studio\gradle
Put the downloaded folder here
Then open studio, setting -, build, execution, deployment – > Gradle modify path to
android-studio/gradle/gradle-2.10
Then you can
Of course, maybe you should change the project settings and open the project location
MyApplication\gradle\wrapper
Modify the file gradle-wrapper.properties
#WedOct2111:34:03PDT2015
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-2.10-all.zip
Something like this will do
Similar Posts:
- Error:Failed to open zip file. Gradle‘s dependency cache may be corrupt (this sometimes occurs after a network connection timeout.)
- [Solved] Could not find method google() for arguments [] on repository container,rn react-native-camera …
- Android studio import project, error e rror:Unsupported method : BaseConfig.getApplicationIdSuffix().
- Could not find com.android.tools.build:gradle:3.3.0.
- Android Studio ERROR: SSL peer shut down incorrectly (Solved)
- [Solved] Android Studio Error: Could not initialize class com.android.sdklib.repository.AndroidSdkHandler
- Gradle‘s dependency cache may be corrupt [How to Solve]
- [Solved] Android Studio Error: Could not initialize class com.android.sdklib.repository.AndroidSdkHandler
- [Solved] Ionic Error: Could not find gradle wrapper within Android SDK.
- Android — problem — Open someone else’s program and report an error