my dog learned polymorphism
The moose likes Beginning Java and the fly likes Running Java programs outside of IDE Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Introducing JavaFX 8 Programming this week in the JavaFX forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Running Java programs outside of IDE" Watch "Running Java programs outside of IDE" New topic
Author

Running Java programs outside of IDE

Travis Sobeck
Greenhorn

Joined: Jun 08, 2005
Posts: 1
I can build programs, compile them, and run them in the IDE just fine. The question is, how do I run the program on a machine with JRE without the IDE?
Jeff Langr
author
Ranch Hand

Joined: May 14, 2003
Posts: 799
    
    5
Use the java executable (java.exe under Windows). Make sure you have a path to the bin directory of your JRE. Then execute something like:



You can set your classpath ahead of time, if necessary, or set it using the -classpath (or -cp) option. For details on the java command, simply enter java at the command line.

-Jeff-


Books: Pragmatic Unit Testing in Java, Agile Java, Modern C++ Programming with TDD, Essential Java Style, Agile in a Flash. Contributor, Clean Code.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Running Java programs outside of IDE
 
jQuery in Action, 3rd edition