File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Beginning Java and the fly likes Run the program that uses Swing component Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Run the program that uses Swing component" Watch "Run the program that uses Swing component" New topic
Author

Run the program that uses Swing component

Elaine Hu
Greenhorn

Joined: Dec 06, 2001
Posts: 1
Hi, I have a question about running any Java program. Usually, after compiling the program successfully, I use the v1.3 interpreter to run the program under Command Prompt; for example: java SwingApplication
However, is Command Prompt the only way to open and run the program? I was wondering if it's possible to make the program automatically execute and run by double-clicking on a small icon, just like when double-clicking on the small ICQ icon, ICQ program opens up and run.
Thanks very much for the help!

Cindy Glass
"The Hood"
Sheriff

Joined: Sep 29, 2000
Posts: 8521
Create a .bat file or whatever and put the commands to start the app in there. Then you can just double click the bat file.


"JavaRanch, where the deer and the Certified play" - David O'Meara
Gregg Bolinger
GenRocket Founder
Ranch Hand

Joined: Jul 11, 2001
Posts: 15299
    
    6

Or create an executable JAR file.
http://java.sun.com/docs/books/tutorial/jar/index.html

------------------
Happy Coding,
Gregg Bolinger


GenRocket - Experts at Building Test Data
 
Consider Paul's rocket mass heater.
 
subject: Run the program that uses Swing component
 
Similar Threads
null ImageIcon from getResource in jar
Setting up JBoss, IntelliJ, and Java EE
Tomcat
running a class in a jar ......
JAR with no Command Prompt involved