How do you end a process using vb.net?

I know you can start a process using this:


System.Diagnostics.Process.Start("Explorer.exe")

You can use this:


Dim myProcess As Process = Process.Start("Explorer.exe") 
        ' yadahyadah 
        ' yadahyadah 
        ' yadahyadah 
        myProcess.CloseMainWindow 

Or


Dim myProcessList As Process() = Process.GetProcessByName("Notepad") 
        Dim myProcess As Process 
        For Each myProcess In myProcessList 
            MyProcess.CloseMainWindow 
            MyProcess.Close 
        Next 

Or


'Kill all running process of Word and Excel. 
        'This is done because of problems with concurrent running Office processes. 
        For Each processXP In processList 
            If processXP.ProcessName = "WINWORD" Or processXP.ProcessName = "EXCEL" Then 
                processXP.Kill() 
            End If 
        Next 

Hope this helps