Resources from appcompat-v7:22.2.0 giving error in Android Studio - android-layout

I have added compile 'com.android.support:appcompat-v7:22.2.0' as dependency in build.gradle. But then also app giving error in accessing many resources from appcompat-v7.
Error:
Error:(25, 64) No resource found that matches the given name (at 'drawable' with value '#drawable/abc_textfield_default_mtrl_alpha').

please provide the detail error stack-trace
In Build.gradle add this in dependencies
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile 'com.android.support:appcompat-v7:22.0.0'
}

Related

The Google Services Plugin cannot function without it. File google-services.json is missing.

File google-services.json is missing. The Google Services Plugin cannot function without it.
Searched Location:
C:\Users\Aman\Desktop\balcony\balcony\Module_SDK\src\nullnull\debug\google-services.json
C:\Users\Aman\Desktop\balcony\balcony\Module_SDK\src\debug\nullnull\google-services.json
C:\Users\Aman\Desktop\balcony\balcony\Module_SDK\src\nullnull\google-services.json
C:\Users\Aman\Desktop\balcony\balcony\Module_SDK\src\debug\google-services.json
C:\Users\Aman\Desktop\balcony\balcony\Module_SDK\src\nullnullDebug\google-services.json
C:\Users\Aman\Desktop\balcony\balcony\Module_SDK\google-services.json
just change in the build.gradle the line
compile fileTree (dir: 'libs', include: ['* .jar'])
to
implementation fileTree(dir: 'libs', include: ['*.jar'])
and ready, your mistake will be corrected!

Using android volley showing error

When I am using android volley for inserting data into server database it is showing error cannot resolve the symbol R.
This is my dependencies in build.gradle(Module: app) where I just used a one line code
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
exclude group: 'com.android.support', module: 'support-annotations'
})
compile 'com.android.support:appcompat-v7:25.1.0'
testCompile 'junit:junit:4.12'
compile 'com.mcxiaoke.volley:library:1.0.19'}/*This line*/
and it is showing error after gradle running.
Cannot resolve the symbol R.
Include this compile 'com.android.volley:volley:1.0.0'.It should work.
try this
compile 'com.mcxiaoke.volley:library-aar:1.0.0'

com.android.build.api.transform.TransformException: java.util.zip.ZipException: duplicate entry: android/support/annotation/CallSuper.class?

I tried all solutions available in stackoverflow. But none of them are working.
this is my dependencies in build.gradle file:
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
testCompile 'junit:junit:4.12'
compile ('com.android.support:appcompat-v7:23.1.1')
compile ('com.android.support:design:23.1.1')
compile ('com.google.android.gms:play-services:8.4.0')
compile files('libs/applovin-6.1.4.jar')
compile files('libs/appodeal-1.13.10.jar')
compile files('libs/chartboost-6.0.2.jar')
compile files('libs/inmobi-5.0.1.jar')
compile files('libs/my-target-4.1.2.jar')
compile files('libs/unity-ads-1.4.7.jar')
compile files('libs/yandex-metrica-android-2.00.jar')
compile ('com.android.support:multidex:1.0.1')
}
when I try to run I get this error:
Error:Execution failed for task ':app:transformClassesWithJarMergingForDebug'.
com.android.build.api.transform.TransformException: java.util.zip.ZipException: duplicate entry: android/support/annotation/CallSuper.class
I have enabled multidex and included in manifest. I checked using ctrl+N, CallSuper is found in two jar files: 1) android.support.annotations and 2) support-v4.
Please help me out in eliminating this error. Thank You.
when we add
compile ('com.android.support:multidex:1.0.1') ,then something else will be added,so i solved my problem by changing
compile ('com.android.support:multidex:1.0.1')
to
androidTestCompile('com.android.support:multidex:1.0.1') {
exclude group: 'com.android.support', module: 'support-annotations'
}

How to create a project in Android Studio without the support library?

I'm sorry if this is a stupid question but I'm new to Android development and for my first app, I don't have any plans to support devices running API 17 and lower so I wish to not use the support library. However, when I create a new project in Android Studio (even with no activity) I can still see
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile 'com.android.support:appcompat-v7:21.0.3'
}
in my Gradle file.
How can I create a project without the support library? Thanks.
You can remove the support library , removing the dependency from your build.gradle
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
//compile 'com.android.support:appcompat-v7:21.0.3'
}
To set minSdk=17 you can use:
android {
defaultConfig {
minSdkVersion 17
targetSdkVersion 22
}
}

How to Include com.questoid.sqlitemanager_1.0.0 jar file in ANDROID STUDIO?? please help on this

How to Include com.questoid.sqlitemanager_1.0.0 jar
file in ANDROID STUDIO?? please help on this
Put it in the folder libs of your app and you have to verify into the builde.gradle the dependecies:
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
}

Resources