java - Console window with javaw? -


I have created a console-based jar program. To be able to run it by clicking jarfile.jar , I went to Registry Editor and went to HKEY_CLASSES_ROOT> jarfile> Shell> Open> Command> (default) to [. ..] javaw.exe [...] to [...] java.exe [...] . It works, but not immediately - I had to change the default program and then it had to change back twice and with this I had to fuck around a bunch (I do not remember at all). There are two drawbacks to this method: One, executable jar files which are not to run with the console, should now be one and it is annoying; Two, if I want to release this program publicly, then whoever wants to use it, has to do the same thing or do it with the java-jar jarfile.jar .

Therefore, I am thinking that there is a way to open the main window of the jar to open its console window which will not be blocked by javaw.exe, so that I can run jar file with jar. I'm thinking something like openConsoleWindow (); OutputTo (theNewWindow ()); Input form (The Newwondo ());

Correct me if I am wrong - you want without using the command line To launch your .jar file? I am not aware of any other way to do this by opening the jar, although you can always create a script which will make the command line material for you, which requires only opening. He or a form of the launcher.


Comments