This week's book giveaway is in the OO, Patterns, UML and Refactoring forum.
We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line!
See this thread for details.
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


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
 
It's not a secret anymore!