Run jar file with JRE

I can't get to run a .jar file with JRE only. it only works with JDK 20 Exception in thread "main" java.lang.UnsupportedClassVersionError: misc/GameRunner has been compiled by a more recent version of the Java Runtime (class file version 63.0), this version of the Java Runtime only recognizes class file versions up to 52.0 I want to build a .exe with JRE bundled in but I can't even get JRE to run my application which was developed in JDK 20
6 Replies
JavaBot
JavaBot2y ago
This post has been reserved for your question.
Hey @Erky! Please use /close or the Close Post button above when you're finished. Please remember to follow the help guidelines. This post will be automatically closed after 300 minutes of inactivity.
TIP: Narrow down your issue to simple and precise questions to maximize the chance that others will reply in here.
Unknown User
Unknown User2y ago
Message Not Public
Sign In & Join Server To View
Erky
ErkyOP2y ago
well that's the next step, i just want to get a zip file with the .exe file and then using launch4j i can set the JRE path to the bin and lib folders which are included in the zip. it works in stackoverflow and tutorials but i cant get my JRE to work @Andrew do u know what to do?
Kyo-chan
Kyo-chan2y ago
Here your JRE is just not the right version. You compiled your classes with JDK 20 and your JRE is lower than that
Erky
ErkyOP2y ago
hmm ok. what do you think I should do to get my .jar file into a runnable .exe that can be run without java?
JavaBot
JavaBot2y ago
💤 Post marked as dormant
This post has been inactive for over 300 minutes, thus, it has been archived. If your question was not answered yet, feel free to re-open this post or create a new one.

Did you find this page helpful?