Win a copy of Practical SVG this week in the HTML/CSS/JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

invoking ms excel from app

 
shilpa reddy
Greenhorn
Posts: 29
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hey,
I would like to invoke an app, for example ms excel from my java app in my actionListener. Any ideas on how to do this.
Thanks in advance,
Shilpa Reddy
 
Ashutosh Uprety
Ranch Hand
Posts: 39
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This will serve ur purpose. Put any other exe in place of notepad. It will work too.
public class Exe {
public static void main(String[] args) {
try {
Runtime r = Runtime.getRuntime();
Process p = r.exec("Notepad");
}
catch(Exception e){
System.out.println(e);
}
}
}
Ashu
 
shilpa reddy
Greenhorn
Posts: 29
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks ashu
Shilpa.
 
Let's get him boys! We'll make him read this tiny ad!
the new thread boost feature brings a LOT of attention to your favorite threads
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!