I'm having an issue with "The System cannot find the file specified"
Here is the part of my code that fails:
var processInfo = new ProcessStartInfo("java", javaParam + " -jar " + jar)
{
CreateNoWindow = true,
UseShellExecute = false,
RedirectStandardOutput = true,
RedirectStandardInput = true,
RedirectStandardError = true,
StandardErrorEncoding = Encoding.UTF8,
StandardOutputEncoding = Encoding.UTF8,
WorkingDirectory = _diretory
};
Process = new Process { StartInfo = processInfo };
Process.Start();
In this image. you can see "Arguments" and "WorkingDirectory". my "craftbukkit.jar" is in my working directory. But It can't find it. locals http://bumisworld.eu/locals.png
And here is the error when I run it outside Visual Studio..
See the end of this message for details on invoking
just-in-time (JIT) debugging instead of this dialog box.
************** Exception Text **************
System.ComponentModel.Win32Exception (0x80004005): The system cannot find the file specified
at System.Diagnostics.Process.StartWithCreateProcess(ProcessStartInfo startInfo)
at System.Diagnostics.Process.Start()
at The_Bukkit_GUI_Project.MinecraftProcess.StartProcess()
at The_Bukkit_GUI_Project.Form1.Start()
at The_Bukkit_GUI_Project.Form1.load_Click(Object sender, EventArgs e)
at System.Windows.Forms.Control.OnClick(EventArgs e)
at Telerik.WinControls.RadControl.OnClick(EventArgs e)
at Telerik.WinControls.UI.RadButtonBase.buttonElement_Click(Object sender, EventArgs e)
at Telerik.WinControls.RadItem.OnClick(EventArgs e)
at Telerik.WinControls.UI.RadButtonItem.OnClick(EventArgs e)
at Telerik.WinControls.UI.RadButtonElement.OnClick(EventArgs e)
at Telerik.WinControls.RadItem.DoClick(EventArgs e)
at Telerik.WinControls.RadItem.RaiseBubbleEvent(RadElement sender, RoutedEventArgs args)
at Telerik.WinControls.RadElement.RaiseRoutedEvent(RadElement sender, RoutedEventArgs args)
at Telerik.WinControls.RadItem.RaiseBubbleEvent(RadElement sender, RoutedEventArgs args)
at Telerik.WinControls.RadElement.RaiseRoutedEvent(RadElement sender, RoutedEventArgs args)
at Telerik.WinControls.RadElement.DoMouseUp(MouseEventArgs e)
at Telerik.WinControls.ComponentInputBehavior.OnMouseUp(MouseEventArgs e)
at Telerik.WinControls.RadControl.OnMouseUp(MouseEventArgs e)
at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
at Telerik.WinControls.RadControl.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
But for some reason. This works on my local computer. But this happens on my remote server. And I have no idea why.. So I'm looking for a little help..