Process.Start("cmd.exe", "/c start  \"title\"  \"C:\\Program Files\\a.bmp\" & pause");

路径含有空格 需要双引号引起来

注意start 后面的第一个参数作用是title参数 不可忽略 且title和path之间需要有空格 否则打不开a.bmp

Process.Start cmd 参数空格问题解决

 

System.Diagnostics.Process.Start(path);//直接start路径更简单

 

相关文章:

  • 2021-12-05
  • 2022-12-23
  • 2022-12-23
  • 2021-12-16
  • 2021-08-13
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2021-12-23
  • 2021-11-12
相关资源
相似解决方案