Could not find or load main class with a Jar File

后端 未结 16 1062
有刺的猬
有刺的猬 2020-12-01 09:09

I\'m trying to load a jar using

@echo off
java -jar Test.jar
pause

With the manifest of

Manifest-Version: 1.0
Main-Class:          


        
16条回答
  •  有刺的猬
    2020-12-01 09:23

    I follow the following instruction to create a executable .jar in Eclipse. Then Run command "java -jar .jar " to launch the program.

    It takes care of creating mainfest and includeing main class and library files parts for you.

    http://java67.blogspot.com/2014/04/how-to-make-executable-jar-file-in-Java-Eclipse.html

提交回复
热议问题