how to run a Jar file during runtime

Runtime.getRuntime().exec("javaw -jar MYJAR.jar");

was what I used to run the jar originally, and it worked. Recently I created an installer for my program, where the user runs a batch-file shortcut which launches the main application. Because the main application is launched from the desktop, rather than directly, the "user.dir" property is different which makes the above code not work. How do I get the name of the folder that contains the running java application?

Thanks

[521 byte] By [Nethera] at [2007-11-27 7:51:15]
# 1
You don't. You fix the installer so that it puts the correct working directory into the shortcut that it creates.
DrClapa at 2007-7-12 19:32:21 > top of Java-index,Java Essentials,Java Programming...