FAILURE: Build failed with an exception.

2
Hi,   while running my application i got below error from mendix studio pro   FAILURE: Build failed with an exception. * What went wrong: The supplied javaHome seems to be invalid. I cannot find the java executable. Tried location: C:\Program Files\Java\jdk-20\bin\java.exe * Try: > Run with --stacktrace option to get the stack trace. > Run with --debug option to get more log output. > Run with --scan to get full insights. * Get more help at https://help.gradle.org
asked
2 answers
1

Try changing your preferences to not use Gradle. 

 

I say this not really knowing what is causing the error other than I had a similar issue with my first attempt at running an app using Mendix 10 and got an error from Gradle. When I turned it off, I was able to compile.

 

I’m sure someone smarter than me will have a more technical solution.

answered
1

Hi Balachandrudu,

I had the same problem while using a different java sdk than the one provided by the Mendix Studio Pro installer. I fixed the problem reverting to the one that the installer provides called “Eclipse Temurin” as shown below in Edit>Preferences:


I hope that helps, regards!

answered