ERROR: cmd.exe failed with args - This is AGONY

Please someone help… I’m struggling with this from a week now! When I try to “Launch” my mobile game on my phone! Android! It gives me this error! I am on engine version 4.26.2!

LogPlayLevel: Error: ERROR: cmd.exe failed with args /c “E:\AAAUE4\XMasClaus\Intermediate\Android\armv7\gradle\rungradle.bat” :app:assembleDeb

Log:

FAILURE: Build failed with an exception.
LogPlayLevel: * What went wrong:
LogPlayLevel: Could not initialize class org.codehaus.groovy.reflection.ReflectionCache
LogPlayLevel: * Try:
LogPlayLevel: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
LogPlayLevel: * Get more help at https://help.gradle.org
LogPlayLevel: BUILD FAILED in 3s
LogPlayLevel: Error: ERROR: cmd.exe failed with args /c “E:\AAAUE4\XMasClaus\Intermediate\Android\armv7\gradle\rungradle.bat” :app:assembleDebug
LogPlayLevel: Took 83.4708026s to run UnrealBuildTool.exe, ExitCode=6
LogPlayLevel: UnrealBuildTool failed. See log for more details. (C:\Users\ivan_\AppData\Roaming\Unreal Engine\AutomationTool\Logs\E+AAAUE4+UE4ACTUALLY+UE_4.26\UBT-XMasClaus-Android-Development.txt)
LogPlayLevel: AutomationTool exiting with ExitCode=6 (6)
LogPlayLevel: Completed Launch On Stage: Build Task, Time: 82.848633
LogPlayLevel: BUILD FAILED
PackagingResults: Error: Launch failed! Unknown Error

Someone PLEASE PLEASE PLEASE help! This is AGONY! ANY SOLUTIONS… PLEASE!

did you solved this error?
Am also getting this error

I thought I would add a bit here that hopefully helps. There could be a number of reason why you are getting this error. Read through your logs before and see if it gives a clue. Some just needed to delete their Intermediate folder and it worked. Many had to go back through their Android Studio setup and make changes.

A way to isolate the problem (if say removing the Intermediate folder does not work) Would be to build a totally blank project with a basic level that works with your headset. Then try to package and/ or launch the project to your headset. If this works, then you have isolated the problem to some extent and will not have to look towards rebuilding or re- installing Android Studio and dealing with settings. From there, it could be something within your current project, asset or setting other than anything regarding Android Studio that is causing the problem. Hope this helps, sometimes you have to troubleshoot what does work and go from there,