日期:2014-05-20  浏览次数:20861 次

VS2005 打包程序中如何运行bat程序?
RT

请大家多多赐教!

------解决方案--------------------
安装部署自定义安装类
System.Diagnostics.Process.Start("cmd.exe", ""); 
Process p = new Process();
p.StartInfo.FileName = "cmd.exe"; //设定程序名

p.StartInfo.UseShellExecute = false;
p.StartInfo.RedirectStandardInput = true;
p.StartInfo.RedirectStandardOutput = true;
p.StartInfo.RedirectStandardError = true;
p.StartInfo.CreateNoWindow = true;
p.Start();
p.StandardInput.WriteLine(@"");
p.StandardInput.WriteLine("exit");
------解决方案--------------------
探讨
安装部署自定义安装类
System.Diagnostics.Process.Start("cmd.exe", "");
Process p = new Process();
p.StartInfo.FileName = "cmd.exe"; //设定程序名

p.StartInfo.UseShellExecute = false;
p.StartInfo.Red……