Question: I'm using ffmpeg to compile videos, and I'd like to prevent it from displaying a console when performing actions.

Here's how I start ffmpeg:

```
ProcessStartInfo si = new ProcessStartInfo();
si.Arguments = string.Format("-y -loop 1 -t " + DucationToString(frameDuration) + " -r 25 -f image2 -i \"{0}\" \"{1}\"",
                             item.Value, otpt);
si.FileName = "ffmpeg";
si.UseShellExecute = false;

Process.Start(si).WaitForExit();

```

No matter the settings I try in `ProcessStartInfo`, the console always shows up.

How do I prevent the console from being shown when creating child process?

Answer: 
You should try to use 

```
ProcessStartInfo si = new ProcessStartInfo();
si.WindowStyle = ProcessWindowStyle.Hidden;
si.CreateNoWindow = true;
si.UseShellExecute = false;

```

[MSDN refs](http://msdn.microsoft.com/en-us/library/system.diagnostics.processstartinfo.windowstyle.aspx)
Set [`ProcessStartInfo.CreateNoWindow`](http://msdn.microsoft.com/en-us/library/system.diagnostics.processstartinfo.createnowindow) to `true`.

**Note** that:

To use `ProcessWindowStyle.Hidden` or `ProcessStartInfo.CreateNoWindow` the `ProcessStartInfo.UseShellExecute` property must be `false`.