The mentioned methods have a few drawbacks:
quote:
You can probably use "start" or "call" DOS command line shell commands with some options to hide that nasty DOS window in the background.
Using javaw instead of java to launch your java program solves this, but the windows task list (or *nix process list) will still show the nondescriptive javaw.exe as the running process, which isn't very nice.
quote:
You can write a really quick C++ or VB to use Exec /exec (C/vb) or CreateProcess to fire it up with whatever windows show/hide, min/max you want.
I'm not very familiar with the windows API (read: not at all) but I think exec and createprocess will spawn new processes and generate additional entries in your task list (ofcourse I could be entirely wrong here
)
However, there is another option (the one I chose when I was messing around with this) which is to use JNI (java native interface) to spawn a java vm and pass your class files to it. However, you will still need a jre installed for the program to run and sun's binary license prevents you from just including the needed files and not the whole JRE. (I might have the code I wrote lying around, it's ugly but it works)
If you want a "native" executable (ie. no VM required) you're out of luck (unless you're willing to spend at least a few hundred dollars) because gcj's (gcc for java) AWT implementation is shoddy at best with lots of unsupported stuff.