title: Using Python to close Chrome Browser on Win7+
body: <p><a href="https://i.stack.imgur.com/1bbvp.png" rel="nofollow noreferrer">The specific task to close</a>
  Ok so i've spent some time researching how to do it and the closest I got was this:</p>
  
  <pre><code>os.system("powershell.exe Get-Process chrome | Stop-Process")
  </code></pre>
  
  <p>but then i got this error:</p>
  
  <p>If I run this command from my CMD it works and the chrome window closes with all tabs included.</p>
  
  <blockquote>
    <p>'Stop-Process' is not recognized as an internal or external command,
    operable program or batch file.</p>
  </blockquote>
  
  <p>I've tried using the 
  '''<code>os.system(taskkill /IM /F chrome.exe)</code>''' (with all its options)</p>
  
  <p>Nothing. the best I got was the 'Oh, Snap' page. (the main chrome proccess didn't close).</p>
  
  <p>Thank you!</p>