Question by Phyire: How can i get my Java Launcher 3 to read the “System.out.println” commands too?
I use Java Launcher 3 to create exe/jar files but when i run the exe file, all my System.out.print commands gets ignored and don’t run… I need them to run otherwise nothing happens. Any help?
Like for example:
String a1 = JOptionPane.showInputDialog(“do you want to run the program?”);
if (a1 .equals (yes))
{
System.out.prinln (“OK”);
}
after i run the exe nothing happens
Best answer:
Answer by deonejuan
When you make a .jar the System.out.println() instructs are deleted from your program. You would have to build a JWindow, probably add the JTextArea, pipe an OutputStream and add code in your program that sends messages to that JWindow.
Add your own answer in the comments!
Take a look at http://java.sun.com/docs/books/tutorial/uiswing/index.html