How to gently close Chrome using CMD or VBS?

前端 未结 2 1107
悲&欢浪女
悲&欢浪女 2021-01-07 07:07

I\'m having a little problem about closing gently Chrome in order to automatically clean cache.

I have a website that is not refreshing correctly, but it does if I cl

2条回答
  •  被撕碎了的回忆
    2021-01-07 07:46

    you can use powershell to close all windows with chrome as process name. It won't kill the task but gently close all chrome browser windows, like if you clicked on top-right cross. Here is the command line to put in batch :

    powershell -command "Get-Process chrome | ForEach-Object { $_.CloseMainWindow() | Out-Null}"
    

提交回复
热议问题