I have searched around a lot but I cannot really find a post that helps I am somewhat new to android so some of this goes over my head. Anyway, my problems started when I go
Change a character -
to :
compile 'com.android.support:appcompat-v7:24.2.1'
rather than
compile 'com.android.support:appcompat-v7-24.2.1'
try
compile 'com.android.support:appcompat-v7:24.2.1'
EDIT
For sdk 27
buildToolsVersion "27.0.3"
implementation "com.android.support:appcompat-v7:27.1.1"
Try adding jcenter
like this way
repositories {
jcenter {
url "http://jcenter.bintray.com/"
}
}
Rather than
repositories {
jcenter()
}
Make sure that this folder exists:
\your-android-sdk\extras\android\m2repository\com\android\support\appcompat-v7\24.0.1
Of course, 24.0.1
should be replaced by the latest version.
I had this problem because I occasionally renamed 24.0.1
to something else and so the required folder couldn't be found.
In build.gradle in all projects, add Marvel and add this URL 'https://maven.google.com'
You can also write like this:
allprojects {
repositories {
jcenter()
maven {
url "https://maven.google.com"
}
}
}