title: C# program with WinRAR
body: <p>I want to design a c# program which can run program a 3rd exe application such as WinRAR. the program will browse for file and when then user click a button, the process to create archive will begin..! </p>
  
  <p>I know using System.Diagnostics.Process.Start method can execute the .exe file. for eg.<pre><code>Process.Start(@"C:\path\to\file.zip");</pre></code></p>
  
  <p>GetFile("filename","open winrar to execute the file") I need something like this. I wanna pass the file name to that 3rd application, without need to open winrar. Is it possible? How should i start? Any references/guidance/solution are very thankful.</p>
  
  <p>thank you very much.</p>
  
  <p><strong><em>//UPDATED</em></strong></p>
  
  <p>Here is the code to open the WinRAR.exe program else the error message appeared.I pun it in button_click and accept file from txtDest.text using browse. So from here, instead of open the files, i want to to compress directly. I try to change "RAR.exe" or "UNRAR.exe" but it didnt work. It is right? </p>
  
  <p>thank you.
  <pre><code> ProcessStartInfo startInfo = new ProcessStartInfo("WinRAR.exe");
   startInfo.WindowStyle = ProcessWindowStyle.Maximized;
   startInfo.Arguments = txtDest.Text;
   try
   {
     // Start the process with the info we specified.
     using (Process exeProcess = Process.Start(startInfo))
      {
          exeProcess.WaitForExit();
      }
    }
    catch
      {
          MessageBox.Show("Error Open");
      }
    }
  </pre></code></p>