Else\r
'Start the encode process\r
Try\r
- Shell("""" + ApplicationPath + "\hbcli.exe""" + list_queue.Items.Item(encodeItems))\r
+ Dim params As String = list_queue.Items.Item(encodeItems)\r
+ Dim proc As New System.Diagnostics.Process\r
+ proc = System.Diagnostics.Process.Start("""" + ApplicationPath + "\hbcli.exe""", params)\r
+\r
+ If My.Settings.Priority <> "Normal" Then\r
+ Dim level As String\r
+ level = My.Settings.Priority\r
+\r
+ Select Case level\r
+ Case "Realtime"\r
+ proc.PriorityClass = ProcessPriorityClass.RealTime\r
+ Case "High"\r
+ proc.PriorityClass = ProcessPriorityClass.High\r
+ Case "Above Normal"\r
+ proc.PriorityClass = ProcessPriorityClass.AboveNormal\r
+ Case "Below Normal"\r
+ proc.PriorityClass = ProcessPriorityClass.BelowNormal\r
+ Case "Low"\r
+ proc.PriorityClass = ProcessPriorityClass.Idle\r
+ End Select\r
+ End If\r
Catch ex As Exception\r
MessageBox.Show("Unable to launch the encoder. Queue run failed.", "Error", MessageBoxButtons.OK, MessageBoxIcon.Hand)\r
MessageBox.Show(ex.ToString)\r