Execute jar from my java code
843849Mar 28 2008 — edited Mar 31 2008Hi,
My CDC application run in Windows Mobile, with Creme JVM.
I need from my java code, run other .jar. and later, finish may application atual.
I try like this:
Runtime.getRuntime().exec("\\Windows\\CrEme\\bin\\CrEme.exe -jar \\Windows\\sample\\cube.jar");
System.exit(0);
But my second jar its not started. Anybody can help me?
Other question, If I getRuntime(), am I using the atual instance of my JVM. If I exec other JAR, and later exit() my atual, the second jar its exit too?
I'm building a automatic upgrade module in my application. With Hessian (Web Service), I download my new jar. But, I need have other jar, start it and close my jar atual. My second jar showld be delete my atual, rename the new jar downloaded for the standard name, and later start the jar download, how new version.
thanks,
Fabio
Edited by: FabioPinheiro on Mar 28, 2008 4:41 AM