'gradle' 'import' was done. Then I got a problem. Help.
D:\bg.jou\GanggoContacts\build.gradle
Error:(25, 13)
Failed to resolve: com.android.volley:volley:1.1.0
<a href="openFile:D:/bg.jou/GanggoContacts_v34_insert_error/build.gradle">Show in File</a><br><a href="open.dependency.in.project.structure">Show in Project Structure dialog</a>
Error:(26, 13)
Failed to resolve: com.github.bumptech.glide:glide:3.7.0
<a href="openFile:D:/bg.jou/GanggoContacts_v34_insert_error/build.gradle">Show in File</a><br><a href="open.dependency.in.project.structure">Show in Project Structure dialog</a>
not complete problem
buildscript {
repositories {
jcenter()
mavenCentral()
maven {
url 'https://maven.google.com/'
name 'Google'
}
}
dependencies {
classpath 'com.android.tools.build:gradle:3.0.1'
classpath 'com.google.gms:google-services:3.1.0'
}
}
dependencies {
//compile 'com.android.support:appcompat-v7:26.1.0'
compile 'com.android.support:appcompat-v7:22.0.0'
compile 'com.google.android.gms:play-services-gcm:11.8.0'
compile fileTree(include: '*.jar', dir: 'libs')
compile project(':fingerpush_3.0.7')
compile 'com.android.volley:volley:1.1.0'
compile 'com.github.bumptech.glide:glide:3.7.0'
}
jcenter() is now deprecated.
Use this in build.gradle of app:
'com.android.volley:volley:1.2.0'
And this in build.gradle:
repositories {
google()
mavenCentral()
}
One of the solutions below must solve your problem:
1- If you've added the following line in your "module/app" build.gradle,
compile 'com.android.volley:volley:1.1.0'
you need to have the following code in your "project" build.gradle in order to enable your programming environment to find and download volley package
allprojects {
repositories {
jcenter()
}
}
2- You are living in a country which is under U.S. and International sanctions and that's why your programming environment cannot connect automatically to jcenter(bintray.com) to download the library, even though you've added jcenter to your repo list. If so, you have to use a proxy while syncing gradle.
Add this snippet to your build.gradle file,
allprojects {
repositories {
google()
jcenter()
}
}
and replace with this -
buildscript {
repositories {
google() // Just google() will be fine
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:3.0.1'
classpath 'com.google.gms:google-services:3.1.0'
}
}
If, you are using gradle version lower than 4.1 - replace google()
with
maven {
url 'https://maven.google.com'
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With