Loading Java JAR through c#
I've made a program that will attempt to open a JAR file by clicking a button in my c# program, unfortunately it won't work.
Here's the code:
Code:
string stdOutput;
int exitCode = ExecuteProcess( @"\"C:\Program Files\Java\jre1.6.0\bin\Java.exe\""
, " -jar myJar.jar "
, @"\"C:\Client\Run.jar""
, myTimeout
, out stdOutput );
The above didn't work, so I tried a different method and replaced with:
Code:
System.Diagnostics.Process.Start(@"c:/Client\Run.jar");
Yet I failed, any suggestions?