Cannot launch Java file "xxx.jar"

I have a java app created by my colleague at work. Our industry has been Windoze dominated for ever, and some of us want to make our software cross-platform. My colleague (a Windows guy) created this Java utility for our customers. IT IS SAFE!!! I could literally slap the guy who wrote it if it isn't.


When I try to launch this on my personal iMac, it fails. The error message says: The Java JAR file "xxxProgramxxx.jar" could not be launched. Check the Console for possible error messages.


I attached a screenshot of the error message and relevant Console output. The Console output goes WAY over my head. What the **** is Sandbox?


2020 27" iMac running Catalina 10.15.7

iMac 27″, macOS 10.15

Posted on Oct 23, 2020 8:58 PM

Reply
Question marked as Top-ranking reply

Posted on Oct 24, 2020 12:56 PM

In Terminal, you need to call the java app which is inside the Java Home for that version. The top level folder is /Library/Java/JavaVirtualMachines.

The home folder is in a folder named for the version.

You can use java_home to locate a home by version. If you have only the one version, you can use this to run that version of java.

`/usr/libexec/java_home`/bin/java -jar xxxxLoader.jar

Similar questions

4 replies
Question marked as Top-ranking reply

Oct 24, 2020 12:56 PM in response to howard4ap

In Terminal, you need to call the java app which is inside the Java Home for that version. The top level folder is /Library/Java/JavaVirtualMachines.

The home folder is in a folder named for the version.

You can use java_home to locate a home by version. If you have only the one version, you can use this to run that version of java.

`/usr/libexec/java_home`/bin/java -jar xxxxLoader.jar

Oct 24, 2020 9:08 AM in response to Barney-15E

Yes to ctrl-clicking and choosing Open. Also tried ctrl-click -> Open With -> Jar Launcher.app.

I have the latest Java Version 8 Update 271 (build 1.8.0_271-b09)

I have had no luck from the command line either, although I confess knowing nothing about using the command. line in OS X. This is what I entered: % open ~/Documents/TEMP-2020-1023/xxxxx_External_Loader_Full_Load_V3/xxxxLoader.jar

The response was that the file did not exist. I double and triple checked the path and filename.

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

Cannot launch Java file "xxx.jar"

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.