Process cmdProcess = null;
                Process unzipProcess = null;

                try
                {
                    cmdProcess = new Process();
                    cmdProcess.StartInfo.UseShellExecute = false;
                    cmdProcess.StartInfo.RedirectStandardInput = true;
                    cmdProcess.StartInfo.RedirectStandardOutput = true;
                    cmdProcess.StartInfo.RedirectStandardError = true;
                    cmdProcess.StartInfo.CreateNoWindow = true;
                    cmdProcess.StartInfo.FileName = "cmd.exe";
                    cmdProcess.Close();
                    cmdProcess.Dispose();
                    cmdProcess = null;

                    unzipProcess = new Process();
                    unzipProcess.StartInfo.FileName = "C:/Program Files/WinRAR/WinRAR.exe";
                    unzipProcess.StartInfo.Arguments = " x -inul -y " + magazineLocal + " " + maNoLocalFold ;//解压的文件和解压到的地方
;
                    unzipProcess.Start();
                    while (!unzipProcess.HasExited)
                    {
                    }
                }
                catch (Exception ex)
                {
                    throw ex;
                }
                finally
                {
                    unzipProcess.Close();
                    unzipProcess.Dispose();
                    unzipProcess = null;
                }

本文使用Blog_Backup未注册版本导出,请到soft.pt42.com注册。

相关文章:

  • 2022-12-23
  • 2021-11-09
  • 2022-12-23
  • 2021-12-16
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2021-12-25
  • 2022-12-23
  • 2021-12-27
  • 2021-09-26
  • 2022-12-23
  • 2021-07-02
  • 2021-09-02
相关资源
相似解决方案