Moment For Technology

The Fatal error compiling for the target version: 11

Posted on Oct. 3, 2022, 4:59 a.m. by Seher Bhandari
Category: The back-end Tag: The back-end

1. Check whether idea configuration is correct

The configuration is correct as follows:

2. Check whether the MVN is correctly bound

This is where I fell! The output is still Java version: 1.8, because in the environment variable, JAVA_HOME still indicates 1.8, which needs to be changed to JDK11's path!

Note: After modifying environment variables, restart IDEA!!

XML and setting.xml of the MVN

If not, select 11 and the following warning will appear:

If that doesn't work, configure Maven's setting.xml:

About (Moment For Technology) is a global community with thousands techies from across the global hang out!Passionate technologists, be it gadget freaks, tech enthusiasts, coders, technopreneurs, or CIOs, you would find them all here.