把要执行的cmd命令放入一个bat文件里,然后执行:
//Process p = Process.Start(bPath);
Process pro = new Process();pro.StartInfo.FileName = bPath;pro.StartInfo.CreateNoWindow = true;pro.StartInfo.WindowStyle = ProcessWindowStyle.Hidden;pro.Start();