Logo 
Search:

Java Forum

Ask Question   UnAnswered
Home » Forum » Java       RSS Feeds

Executing JAR

  Asked By: Jose    Date: Apr 06    Category: Java    Views: 816
  

I installed latest version of JRE and wanted to run
Java program from jar file. I tried executing java
program by command "jre -cp app.jar MainClass" but for
some reason, my system doesn't recognize jre command.
Can anybody tell me what may be the problem?

Share: 

 

1 Answer Found

 
Answer #1    Answered By: Willis Hill     Answered On: Apr 06

Try:

java -cp app.jar MainClass

If this doesn't work then verify that the JRE/bin path is in your PATH
environment variable.

 
Didn't find what you were looking for? Find more on Executing JAR Or get search suggestion and latest updates.




Tagged: