| | |
How can i run this program from a jar.
![]() |
I am using IBM Websphere, and from here i can just click Run As java application, and the program runs inside websphere. But i want to run the program outside IDE.
I created a jar file and everthing is correct with it. It has the MANIFEST.MF and all.
So what do i need to do to run this from cmd.exe? I would like cmd to open when the jar file is double clicked so that the program will use the command line as the input?
Thanks, sj
I created a jar file and everthing is correct with it. It has the MANIFEST.MF and all.
So what do i need to do to run this from cmd.exe? I would like cmd to open when the jar file is double clicked so that the program will use the command line as the input?
Java Syntax (Toggle Plain Text)
import java.io.*; // Java I/O classes public class L3P3 { public static void main(String []arg) throws IOException // throws IOException { BufferedReader input = new BufferedReader(new InputStreamReader(System.in)); System.out.println("Enter in your full name"); String s1 = input.readLine(); StringBuffer tmp = new StringBuffer(s1); String s2 = tmp.reverse().toString(); System.out.println("Your reversed name is " + "\"" + s2 + "\""); } }
Thanks, sj
•
•
Join Date: May 2008
Posts: 1
Reputation:
Solved Threads: 0
Thank you for this was helpful to me.
But I tried like like you said but it giving error
Please any body help me? I used Eclipse3.2.2
But I tried like
Java -jar blpack.jar •
•
•
•
Failed to load Main-Class manifest attribute from blpack.jar
How to make a Jar File I used this to learn how. The author explains it very well.
"Argyou not with the hand you are dealt in cards or life." ---- Wizard and Glass
![]() |
Similar Threads
- how run a exe on a program (C#)
- how to run javascript program (JavaScript / DHTML / AJAX)
- QBasic, what can i do to make my programs run without the QBasic program? (Legacy and Other Languages)
- Could I run applications using just the Program Files from another computer? (Windows NT / 2000 / XP)
- run external program asociated with extension (C)
- how to run javascript program (JavaScript / DHTML / AJAX)
- Error in EJB client program (javax.naming.NoInitialContextException) (Java)
Other Threads in the Java Forum
- Previous Thread: Inserting a Data Grid
- Next Thread: java code
| Thread Tools | Search this Thread |
-xlint actionlistener android api applet application array arrays automation bi binary blackberry block bluetooth character chat class client code compile component consumer database desktop developmenthelp eclipse error fractal freeze ftp game gameprogramming givemetehcodez graphics gui html ide image input integer j2me j2seprojects java javac javaee javaprojects jni jpanel jtable julia learningresources lego linked linux list loop loops mac map method methods mobile netbeans newbie notdisplaying number online printf problem program programming project properties qt recursion researchinmotion rotatetext rsa scanner screen server set singleton sms sort sql string swing system textfields threads time title tree tutorial-sample update variablebinding windows working xor






