Calling exe through Java program.

Calling exe through Java program.

Hi,

How to call a vb exe that takes one argument , using a Java program.

Thank You,

Umesh Kilkile
View Answers

July 15, 2010 at 11:25 AM

Hi Friend,

Try the following code:

import java.lang.*;
import java.io.*;

public class Invoke{
public static void main(String args[])throws IOException{
Runtime r=Runtime.getRuntime();
Process p=null;
try {
String s="C:\\eclipse\\eclipse.exe";
p=r.exec(s);
}
catch(Exception e){
System.out.println(e);
e.printStackTrace();
}
}
}

Hope that it will be helpful for you.
Thanks

March 22, 2011 at 11:04 AM

Thanx for reply but this code only execute local machine program. i want run exe on remote machine. if there is any idea then give thanx again.


March 3, 2013 at 9:20 PM

dude but where is the argument passed in your code ?









Related Tutorials/Questions & Answers:
Calling exe through Java program. - Java Beginners
Calling exe through Java program.  Hi, How to call a vb exe that takes one argument , using a Java program. Thank You, Umesh Kilkile  Hi Friend, Try the following code: import java.lang.*; import
Server calling of .exe file in the client
Server calling of .exe file in the client   I have a requirement with java webapplication. We are using jboss as appserver on Linux machine. How can I call a .exe file from client machine? I want to run .exe from webpage like
Advertisements
how to start intergrated webcam of a laptop without calling its exe file using java only - Java Beginners
how to start intergrated webcam of a laptop without calling its exe file using java only  how to open integrated webcam of a laptop without calling its exe file using java only?.simply what i am asking is that is there any method
calling from iphone through programitically in iphone
calling from iphone through programitically in iphone  calling from iphone through programitically in iphone please help me my senario is if i click send sms button message should deliver to xyz person and that xyz person make
.EXE - Java Beginners
.EXE  Hello all, I have to convert my java program into .exe file format. Actually i created program like string to hexa decimal and run in the command prompt, but i want to convert java program into .exe format, i dont have
.Exe - Java Beginners
.Exe  Hai I created some java program its compailing and showing o/p. I want to convert my java program into .EXE file because i want to put my java program into PDA so PDA not having much space. So pls tell me the procedure
creating an .exe file - Java Beginners
creating an .exe file  how to create an .exe file in java? thanks in advance
Invoking exe - Java Beginners
Invoking exe  Hi, How can I invoke a exe with command line arguments in java.   Hi Friend, Try the following code: import java.lang.*; import java.io.*; public class Invoke{ public static void main
To make java exe or runnable file
To make java exe or runnable file   Helo sir i make a java application.I need to help how run application direct in pc i.e how it packaged, .exe file or setup file
calling a java file in java
calling a java file in java  how to call a another java file in java
set java exe file as background - Java Beginners
set java exe file as background  hi frenz, i am begineer to java. in my application i have a one exe file. now i wanna the file... is closed then v don't continue that application.. can u tell me how java exe file set
calling method - Java Beginners
calling method   class A{ public void fo(){ class B{ public void fo1(){ System.out.println("fo1 of class B"); } } System.out.println("fo of class A"); } class C{ public void fo2
how to call an exe file from java - Java Beginners
how to call an exe file from java  hi, how to call exe file with some parameters from java and save the output of the exe file in a specified path. Please let me know immediately..its urgent!!! Thanks in advance
calling java beans - JSP-Servlet
calling java beans  Sir, I want to know where to place the java beans java file and class file inside tomcat web server. and how to call them from jsp file.  Hi Friend, Java Bean is placed in classes\form
how to convert war file into .exe file using java code
how to convert war file into .exe file using java code  hi,I am beginner in the java,I want to convert my java maven project to .exe file,plz tell me which is required jar files and how i convert this..?Thanks in advance
invoking exe files on sound
invoking exe files on sound  how to invoke .exe files on input as sound in java
sql connectivity through java
sql connectivity through java  i want an example for java db through sql connection. Thanks in advance
ModuleNotFoundError: No module named 'exe'
ModuleNotFoundError: No module named 'exe'  Hi, My Python program is throwing following error: ModuleNotFoundError: No module named 'exe' How to remove the ModuleNotFoundError: No module named 'exe' error
ModuleNotFoundError: No module named 'exe'
ModuleNotFoundError: No module named 'exe'  Hi, My Python program is throwing following error: ModuleNotFoundError: No module named 'exe' How to remove the ModuleNotFoundError: No module named 'exe' error
exe set up software - Java Server Faces Questions
exe set up software  hi i want a exe file creator software. i am doing a project in swings. now i need exe converter. pls send
write a program to create an vector and listeterator.and value should be enter through keyboard.
write a program to create an vector and listeterator.and value should be enter through keyboard.  write a program to create an vector and listeterator.and value should be enter through keyboard
write a program to create an arraylist and listeterator.and value should be enter through keyboard.
write a program to create an arraylist and listeterator.and value should be enter through keyboard.  write a program to create an arraylist and listeterator.and value should be enter through keyboard
write a program to create an vector and listeterator.and value should be enter through keyboard.
write a program to create an vector and listeterator.and value should be enter through keyboard.  write a program to create an vector and listeterator.and value should be enter through keyboard
write a program to create an vector and listeterator.and value should be enter through keyboard.
write a program to create an vector and listeterator.and value should be enter through keyboard.  write a program to create an vector and listeterator.and value should be enter through keyboard
write a program to create an arraylist and listeterator.and value should be enter through keyboard.
write a program to create an arraylist and listeterator.and value should be enter through keyboard.  write a program to create an arraylist and listeterator.and value should be enter through keyboard
Calling external process in Java - Java Beginners
Calling external process in Java  Hi, How I can call some system command from Java? I want to run the Microsoft Calculator application from Java, how it can be done. Provide me example. What is the use of Runtime.getRuntime
Calling java class method from javascript
Calling java class method from javascript  I want to call a java class method from javascript. The java class method is like "public String[] getWord()". I want to assign this string array value to a variable in javascript. I
Run a .exe from a class
Run a .exe from a class  how to lauch a .exe file from a class in Java and to check the success ful execution of the same
WRITE A PROGRAM TO PRINT OUT THE NUBERS 10 THROUGH 49
WRITE A PROGRAM TO PRINT OUT THE NUBERS 10 THROUGH 49   write a program to print out the number 10 through 49 in the following manner 10 11 12 13 ......19 20 21..............29 30 31..............39 40 4142............49
Error in calling javascript function from java
Error in calling javascript function from java  I am callin javascriot function from applet and getting error netscape.javascript.JSException: Unexpected error: This method should not be used unless loaded from plugin.jar
exe file creation - JDBC
exe file creation   hi i have done a project in java swings.project name is format migrator.means db migrator. now my aim is create EXE FILE for my project. pls do consider
how to create .exe file of java application?? - Java Beginners
how to create .exe file of java application??  hi i want to know how to create exe file of whole application so that i can use that application on any other computer.. i will be very thankful to you..  Hi
core java ,io operation,calling methods using switch cases
core java ,io operation,calling methods using switch cases  How to create a dictionary program,providing user inputs using io operations with switch cases and providing different options for searching,editing,storing meanings
Creating an exe file
Creating an exe file  Hi All, I have developed java application using swing by Net Beans IDE. Now I need to convert my application into exe file... as an exe file. Please anyone suggest me.Thanks in Advance. Thanks, T.Thanga meena
ModuleNotFoundError: No module named 'run-exe'
ModuleNotFoundError: No module named 'run-exe'  Hi, My Python program is throwing following error: ModuleNotFoundError: No module named 'run-exe' How to remove the ModuleNotFoundError: No module named 'run-exe
ModuleNotFoundError: No module named 'run-exe'
ModuleNotFoundError: No module named 'run-exe'  Hi, My Python program is throwing following error: ModuleNotFoundError: No module named 'run-exe' How to remove the ModuleNotFoundError: No module named 'run-exe
ModuleNotFoundError: No module named 'dist-exe'
ModuleNotFoundError: No module named 'dist-exe'  Hi, My Python program is throwing following error: ModuleNotFoundError: No module named 'dist-exe' How to remove the ModuleNotFoundError: No module named 'dist-exe
ModuleNotFoundError: No module named 'hack-exe'
ModuleNotFoundError: No module named 'hack-exe'  Hi, My Python program is throwing following error: ModuleNotFoundError: No module named 'hack-exe' How to remove the ModuleNotFoundError: No module named 'hack-exe
Implement Java clients calling Web Services
Implement Java clients calling Web... the enterprise components Next    Implement Java clients calling Web Services Generating a Java client proxy and a sample
video calling
video calling  how to implement video calling using java? i am a final year mca student please give me some samplecodes
video calling
video calling  how to implement video calling using java? i am a final year mca student please give me some samplecodes
Overview of Networking through JAVA
Overview of Networking through JAVA The Java platform is extremely preferable to write an application program require to communicate with the resources... client program and a server program. In java there is a java.net package
Overview of Networking through JAVA
Overview of Networking through JAVA The Java platform is extremely preferable to write an application program require to communicate with the resources... client program and a server program. In java there is a java.net package
a java program
a java program  Write a java program that accepts positive numbers... through the link may, this will be helpful for you http://www.roseindia.net/java/thread/java-multithreading-example.shtml Thanks
Calling from JSP
Calling from JSP  how can we call a class file from JSP   Hi, Do you want to call a servlet or a Java Bean through JSP? Please clarify this. For more information, visit the following link: JSP Tutorials Thanks
First Java Program
your first Java program. In Java, all source code is written in plain text file... Machine. You can write a Hello World program as your first Java program. To write... the java HelloWorld.java command and to execute the program use java
write a program to create an arraylist with string(add,remove) operation.and value should be enter through keyboard.
write a program to create an arraylist with string(add,remove) operation.and value should be enter through keyboard.  write a program to create an arraylist with string(add,remove) operation.and value should be enter through
write a program to create an vector with string(add,remove) operation.and value should be enter through keyboard.
write a program to create an vector with string(add,remove) operation.and value should be enter through keyboard.  write a program to create an vector with string(add,remove) operation.and value should be enter through keyboard
write a program to create an arraylist with string(add,remove) operation.and value should be enter through keyboard.
write a program to create an arraylist with string(add,remove) operation.and value should be enter through keyboard.  write a program to create an arraylist with string(add,remove) operation.and value should be enter through
Calling Destructor
Calling Destructor  How can i call destructor in java using System.gc() or manually. Please anyone give me a example program   Java... to the file."); } } Java Garbage Collection using System.gc

Ads