I'm new to Android Studio and it was working just fine and I made few apps and they worked pretty well, and then I downloaded a project from GitHub and tried to import it, the project didn't work but now every time I make new project this error happens:(I can't upload pictures)
Import android.support.v7.app.AppCompatActivity
;
The 'v7' is colored in red and it says it can't resolve symbol v7
In the messages it giving me this:
Unable to resolve dependency for ':app@debug/compileClasspath': could not resolve com.android.support:appcompat-v7:26.0.0-beta1)
I tried the following:
But nothing worked.
I have Android studio 3.0.1
Android emulator 27.1.12
Android SDK platform tools 27.0.1
Android SDK tools 26.1.1
To use support libraries starting from version 26.0.0 you need to add Google's Maven repository to your project's build.gradle file as described here: https://developer.android.com/topic/libraries/support-library/setup.html
allprojects {
repositories {
jcenter()
maven {
url "https://maven.google.com"
}
}
}
For Android Studio 3.0.0 and above:
allprojects {
repositories {
jcenter()
google()
}
}