I've just installed android studio and there's an error I don't know how to fix
This question is related to
android
How to fix app:mergeDebugResources in Android Studio (Resource path could not resolved / R.id is not accessible)
This should resolve your Gradle issue.. good luck.
In My case, I've written below code in build.gradle
android {
// ...
aaptOptions.cruncherEnabled = false
aaptOptions.useNewCruncher = false
// ...
}
It's work for me!...
Okay here is a simple fix.
This error popped in front of me when I tried to manually change .jpg file to .png and then was copying & pasting it in my 'drawable' folder.
I rebuild and cleaned Project many times but nothing happened, then I removed that .png image and replaced that file with a different pre-existing .png image (or you can change it by help of paint and then paste it in drawable folder)
Now rebuild and clean the project . It works.
Hope it helps..!
I had that problem, but it was because my images changed them manually from .JPG to .PNG, so I just changed them with PNG paint and solved the problem
For me. I changed the color of .xml image (vector image) like this.
ic_action_add.xml
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24"
android:tint="#FFFFFF"
android:alpha="0.8">
<path
android:fillColor="@android:color/white"
android:pathData="M19,13h-6v6h-2v-6H5v-2h6V5h2v6h6v2z"/>
</vector>
to:
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24"
android:tint="#FFFFFF"
android:alpha="0.8">
<path
android:fillColor="#FF000000"
android:pathData="M19,13h-6v6h-2v-6H5v-2h6V5h2v6h6v2z"/>
</vector>
i just changed android:fillColor="@android:color/white"
to android:fillColor="#FF000000"
and it's worked for me :)
By default, Android Studio has a maximum heap size of 1280MB. If you are working on a large project, or your system has a lot of RAM, you can improve performance by increasing the maximum heap size for Android Studio processes, such as the core IDE, Gradle daemon, and Kotlin daemon.
If you use a 64-bit system that has at least 5 GB of RAM, you can also adjust the heap sizes for your project manually. To do so, follow these steps:
Click File > Settings from the menu bar (or Android Studio > Preferences on macOS). Click Appearance & Behavior > System Settings > Memory Settings.
For more Info click
If you have recently used ionic cordova resources or ionic resources command please check the files generated in folders of platform/build/res there might be some files corrupted , so just delete those files and build the apk.. hope it helps someone worked for me
Try clean project...
If it doesn't work... Then... Goto build.gradle in project section
Try downgrading the gradle version
From...
dependencies {
classpath 'com.android.tools.build:gradle:1.5.0'
}
To...
dependencies {
classpath 'com.android.tools.build:gradle:1.2.0'
}
Then gradle.properties, add this
org.gradle.jvmargs=-XX\:MaxHeapSize\=256m -Xmx256m
Sync it... Clean/Rebuild... It worked for me... So, I am sharing...
For me upgrading gradle version and plugin to the latest version did the trick.
I can see libc error in the log.
install these packages in your system
sudo apt-get install lib32stdc++6 lib32z1 lib32z1-dev
Restart android studio after installation
This issue can be resolved by trying multiple solutions like:
Source: Stackoverflow.com