Fix launch external programs in client
This commit is contained in:
@@ -254,7 +254,11 @@ namespace CMS_Client.Browser_Tools
|
||||
if (p.Count() > 0 && p[0].MainWindowHandle != IntPtr.Zero)
|
||||
NcWindow.ForceExtFocus(p[0].MainWindowHandle);
|
||||
else
|
||||
Process.Start(sft.path, sft.arguments);
|
||||
{
|
||||
ProcessStartInfo PS = new ProcessStartInfo(sft.path, sft.arguments);
|
||||
PS.WorkingDirectory = new FileInfo(sft.path).Directory.FullName;
|
||||
Process.Start(PS);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -263,7 +267,11 @@ namespace CMS_Client.Browser_Tools
|
||||
{
|
||||
Software sft = Config.ExtSoftwaresConfig.FirstOrDefault(X => X.id == (string)id);
|
||||
if (sft != null)
|
||||
Process.Start(sft.path, sft.arguments);
|
||||
{
|
||||
ProcessStartInfo PS = new ProcessStartInfo(sft.path, sft.arguments);
|
||||
PS.WorkingDirectory = new FileInfo(sft.path).Directory.FullName;
|
||||
Process.Start(PS);
|
||||
}
|
||||
}
|
||||
|
||||
#endregion PROCESSES_METHODS
|
||||
|
||||
Binary file not shown.
Reference in New Issue
Block a user