TQ for this info Pieter. Have to play around with the Environment variables.

Warm regards

Amitabh Choudhury

On Tue, Oct 25, 2022 at 10:26 PM Pieter van den Hombergh <
pieter.van.den.hombe...@gmail.com> wrote:

> the path is a sequence of directories. the algorithm that tries to find an
> executable file uses the directies in path order and the first file in any
> directory that matches the request is the one used. so adding a directory
> at the end will have no effect if an earlier directory satisfies the
> request.
>
> Op di 25 okt. 2022 09:02 schreef Amitabh Choudhury <
> amitabhisg...@gmail.com>:
>
>> Hello Alexander and Ernie
>>
>> Thanks for the reply.
>> Was able to get into the System variable of Windows 11 and found that
>> "Path" started with "C:\Program Files (x86)\Common
>> Files\Oracle\Java\javapath".
>> Even though 1.18 was installed and placed in "Path" at the end, the x86
>> javapath was being picked up and had version 1.8.
>> deleted the string from "Path" and was able to get the app
>> (GabellatteMVPn) running.
>>
>> Meanwhile got aware of (https://javaalmanac.io/bytecode/versions/). TQ
>> Ernie.
>>
>> Warm regards
>>
>> Amitabh Choudhury
>>
>> On Tue, Oct 25, 2022 at 10:49 AM Ernie Rael <err...@raelity.com> wrote:
>>
>>> On 22/10/24 10:14 PM, Ernie Rael wrote:
>>> > On 22/10/24 9:50 PM, Amitabh Choudhury wrote:
>>> >> Hi
>>> >>
>>> >> I am not exposed to under the hood of netbeans settings, hence
>>> >> require hand-holding.
>>> >>
>>> >> Application is working fine in Netbeans IDE. But when I use a
>>> >> shortcut link to the jar file or try to run in the console, I get the
>>> >> following error message.
>>> >> ~~~~~
>>> >> Error: A JNI error has occurred, please check your installation and
>>> >> try again
>>> >> Exception in thread "main" java.lang.UnsupportedClassVersionError:
>>> >> gabellattemvpn/GabellatteMVPn has been compiled by a more recent
>>> >> version of the Java Runtime (class file version 62.0), this version
>>> >> of the Java Runtime only recognizes class file versions up to 52.0
>>> >> ~~~~~
>>> >
>>> > Taking a look at https://javaalmanac.io/bytecode/versions/
>>> >
>>> > I see that 52 is java 8, 62 is java 18.
>>> >
>>> > Your jre is java 8 (presumably this is the default jre on your windows
>>> > system), you compiled it (assuming GabellatteMVPn is yours), on java
>>> 18.
>>> >
>>> > I'd be inclined to update your system with a newer jre. The
>>> > alternative is to compile your program to run on java 8.
>>> >
>>> > -ernie
>>>
>>> And of course, you can use the jdk/jre that NetBeans runs on to execute
>>> your jar file.
>>>
>>> -ernie
>>>
>>> >
>>> >>
>>> >> Please inform what changes have to be done and where
>>> (Netbeans/Console).
>>> >>
>>> >> I am using MS Windows 11(or 10).
>>> >>
>>> >> Warm regards
>>> >>
>>> >> Amitabh Choudhury
>>> >>
>>> >>
>>> >>
>>> >
>>> >
>>> > ---------------------------------------------------------------------
>>> > To unsubscribe, e-mail: users-unsubscr...@netbeans.apache.org
>>> > For additional commands, e-mail: users-h...@netbeans.apache.org
>>> >
>>> > For further information about the NetBeans mailing lists, visit:
>>> > https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
>>> >
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscr...@netbeans.apache.org
>>> For additional commands, e-mail: users-h...@netbeans.apache.org
>>>
>>> For further information about the NetBeans mailing lists, visit:
>>> https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
>>>
>>>

Reply via email to