File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Beginning Java and the fly likes Closing Applications Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Closing Applications" Watch "Closing Applications" New topic

Closing Applications

james wilson

Joined: Nov 17, 2001
Posts: 15
I currently use the follownig code to open a browser from my application;
Runtime rt = Runtime.getRuntime();
Process proc = rt.exec("c:\\Program Files\\Internet Explorer\\IEXPLORE.EXE");
What I want to do is also to be able to close this appliation from my Java application, is this possible?
To take this a step further, is it possible to close any other application that is running, even if you don't know what is running?
Thanks in advance
John Dale
Ranch Hand

Joined: Feb 22, 2001
Posts: 399
The API documentation seems to say that after
Process child=Runtime.getRuntime().exec(command);
you could
wood burning stoves
subject: Closing Applications
Similar Threads
running tomcat
Logfile from different classes
Scheduler application architecture
from servlet wants to close the application
J2EE/J2SE JMS message