How to launch command line Java code inside a JFrame?

本秂侑毒 提交于 2020-03-22 07:37:11

问题


I have a Java program which is executed through the basic command line interface. I am wondering about put it in a window JFrame. Is it possible? How can I do?

Thank you.


回答1:


If you want command line inside a jFrame I think it is not a good idea. If the JFrame is started that means the program is already started. You have to start the program using command line or running a executable jar file.So there is no meaning in what you are going to do.

If you want to see your output inside a JFrame rather than in the command line, that can be done. You can look here for details of swing programmimng



来源:https://stackoverflow.com/questions/8200707/how-to-launch-command-line-java-code-inside-a-jframe

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!