Forums Register Login

DOS window still coming when I run the Application using javaw

+Pie Number of slices to send: Send
I am running xindice using javaw but ,it is still showing the DOS window.Can any body tell me how can I come over it..
+Pie Number of slices to send: Send
hello do you know why javaw is used for...it is used to open the executable jar file.
please study the documentation..if you dont have doc please refer me..Okay
:-)
+Pie Number of slices to send: Send
have you tried adding 'start'?
as in:
start javaw my.App
I don't actually care enough to go find out the diffence, but this is what i generally do.
+Pie Number of slices to send: Send
Hi All,
I've been avoiding this one but start doesn't work either. I tried writing a small java boot program that used "start java prog" but it threw an exception in Win32Process. I even tried writing a C++ boot program to do the same thing using CreateProcess and it just sat there looking stupid: the java VM never started. The only other possibility I can think of is to write a C++ program and use spawn and then cut the parent loose from the child and then have the parent exit.
Boy some things are so much easier to do in Unix/Linux!
Michael Morris
+Pie Number of slices to send: Send
OK, I was lazy and didn't state that I believe 'start' only works in NT/2k/XP.
I know it works in some cases and these are the only ones I've tested it in.
+Pie Number of slices to send: Send
Well, I am a bit confused. How are you running javaw xindice in the first place? From a batch file? I don't think that javaw is intended to get rid of the DOS screen as in it does not appear. I know that when you launch a java program using javaw from the DOS prompt, then you can close that DOS prompt without terminating the java application. It is the same as saying:
java xindice &
in linux. It runs the app as a seperate process from the DOS window.
Now, I have noticed that when running a batch file that uses javaw, in Windows 95, the DOS window opens then closes almost immediatly. But on Windows XP the DOS window stays open and I just have to close it.
Have not tested on other OS's.
[ August 08, 2002: Message edited by: Gregg Bolinger ]
+Pie Number of slices to send: Send
Hi David,
I'm using Win 2k Pro. Can't get rid of the damn command window no matter what I try. Batch files, boot programs, start, javaw, whatever. Another big problem with this is that just closing the command window will kill the VM that it owns without notifying it. So you can't prevent a user from shutting down, possibly leaving your program in a state of disarray. I hope someone comes up with a solution for this.
Michael Morris
+Pie Number of slices to send: Send
 

Originally posted by Michael Morris:
Hi David,
Another big problem with this is that just closing the command window will kill the VM that it owns without notifying it. So you can't prevent a user from shutting down, possibly leaving your program in a state of disarray.
Michael Morris


This is not true if you use JAVAW to launch you application.
+Pie Number of slices to send: Send
Hi all,
I just tried using "javaw" and my java boot program does work using "javaw" instead of "start java" but as Greg indicated on NT Kernal machines you have to manually close the command box.
Here's the boot program:

Of course it wouldn't be too dificult to pass the class file and any parameters for it in main's args, instead of a hardwiring it.
Michael Morris
Everybody's invited. Except this tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com


reply
reply
This thread has been viewed 2338 times.
Similar Threads
DOS command window
How to eliminiate the background ms-dos window
Annoying DOS window
javaw and bat files
javaw
More...

All times above are in ranch (not your local) time.
The current ranch time is
Mar 28, 2024 09:59:56.