I\'m using System.Diagnostics.ProcessStartInfo to set up the parameters for launching a process from a .NET program. Once the the process is started, I can use
There is no provided API in the Process class to start a process with a different priority. The best option is to just set it immediately after starting the process. Once you start the process, you can set the Process.PriorityClass:
var myProcess = Process.Start(...);
myProcess.PriorityClass = ProcessPriorityClass.Idle;
If you wish to prevent the process from running with a higher priority, darin's answer provides a workaround using P/Invoke and the Windows API. Even this starts the process with a normal priority, but if it's started in a suspended state, it will not run, so the priority would have no effect.
Start the process suspended, then change the priority, and then resume the process. You do this with the CreateProcess Win32 function using the CREATE_SUSPENDED flag but unfortunately I am not sure if there's support in .NET for this and you might need to resort to P/Invoke.