0

Hello this is my first time make android program and found this error but the code not have an error point. the error message is below :

Execution failed for task ':app:mergeDebugResources'.

Could not resolve all files for configuration ':app:_internal_aapt2_binary'. Failed to transform aapt2-4.1.1-6503028-windows.jar (com.android.tools.build:aapt2:4.1.1-6503028) to match attributes {artifactType=_internal-android-aapt2-binary, org.gradle.libraryelements=jar, org.gradle.status=release, org.gradle.usage=java-runtime}. > Execution failed for Aapt2Extractor: C:\Users\lenovo.gradle\caches\modules-2\files-2.1\com.android.tools.build\aapt2\4.1.1-6503028\cc838ebadee3649d47e07d029371bc1054e2200d\aapt2-4.1.1-6503028-windows.jar. > java.io.IOException: Unable to delete directory 'C:\Users\lenovo.gradle\caches\transforms-2\files-2.1\aa8b5888abc00f78a9403248465821cc' Failed to delete some children. This might happen because a process has files open or has its working directory set in the target directory. - C:\Users\lenovo.gradle\caches\transforms-2\files-2.1\aa8b5888abc00f78a9403248465821cc\aapt2-4.1.1-6503028-windows

can someone tell me how to fix it ?

1 Answers1

0

i had same problem in linux tried many ways and asked some question. finally found out there is file missing named aap2 in build-tools i couldn't find that file to place it in destination so i deleted whole file and re Download it with sdk manager and if it doesn't work too i guess u should try reinstall android studio yes its not a good answer but it was all experience i had with this error.

yasin naqash
  • 51
  • 1
  • 2
  • thanks for you suggest. i found the problem wherever i must manually delete some cache file on C:\Users\lenovo.gradle\caches\transforms-2\files-2.1\aa8b5888abc00f78a9403248465821cc – Christian Darmawan Nov 21 '20 at 14:15