SVN-Revision: r924
This commit is contained in:
cyf
2025-08-07 09:29:22 +00:00
parent f7a53010be
commit e6ec3e4886
27 changed files with 4288 additions and 277 deletions
@@ -513,8 +513,24 @@ namespace Lskj.Control.Model
// 特殊处理程序
else if (dllName.Contains(".exe") && !model.WipeExes.Contains(dllName.ToString()) && (dllName.ToLower() != "lstest.exe"))
{
//删除选中行的json信息
if(!string.IsNullOrWhiteSpace(maintabFocusedRowJson))paramList.Remove(maintabFocusedRowJson);
// 创建进程启动信息对象
ProcessStartInfo startInfo = new ProcessStartInfo();
startInfo.FileName = File.Exists(dllName) ? dllName : PubUtil.AbsolutelyLibPath + dllName; // 指定要启动的 EXE 路径
// 将参数数组拼接为命令行字符串(注意空格处理)
// 若参数包含空格,需要用双引号包裹,避免被解析为多个参数
startInfo.Arguments = string.Join(" ", paramList.Select(arg =>
arg.Contains(" ") ? $"\"{arg}\"" : arg
));
// 可选:设置进程启动选项
startInfo.UseShellExecute = false; // 不使用系统外壳程序(建议为 false,便于重定向输入输出)
startInfo.CreateNoWindow = false; // 是否在新窗口中启动(false 为显示窗口)
// 启动进程
Process process = Process.Start(startInfo);
// 执行exe程序
WinHelper.WinExec(File.Exists(dllName) ? dllName : PubUtil.AbsolutelyLibPath + dllName, 1);
//WinHelper.WinExec(File.Exists(dllName) ? dllName : PubUtil.AbsolutelyLibPath + dllName, 1);
}
else if (dllName.StartsWith("www.") ||