简体   繁体   English

批量强制 Windows 计算器在 Windows 10 中关闭

[英]Batch force windows calculator to close in Windows 10

I have three monitors, and I like to play SMITE in triple surround.我有三台显示器,我喜欢在三重环绕声中玩《神之浩劫》。 To do this the NVIDIA Control Panel wants me to close a few (to me random) applications before it can do its magic.为此,NVIDIA 控制面板要我关闭一些(对我来说是随机的)应用程序,然后它才能发挥它的魔力。 This is all good and well, but the calculator application is a pain to close.这一切都很好,但是计算器应用程序很难关闭。 I have to use the task manager to force the process to stop, because for some reason it doesn't always by itself.我必须使用任务管理器强制进程停止,因为出于某种原因它并不总是自己停止。

I want to use a batch script for this, so it will close automatically with only a single double click (along with some other applications that sometimes do and sometimes don't need to be closed)我想为此使用批处理脚本,因此只需双击即可自动关闭(以及其他一些有时需要关闭有时不需要关闭的应用程序)

But since the calculator isn't just a simple.exe, I can't figure out how to shut it down.但由于计算器不仅仅是一个 simple.exe,我不知道如何关闭它。 What I've found for a regular process is taskkill /f /im processname.exe but, the calculator doesn't have a simple.exe I can kill.我发现的常规进程是taskkill /f /im processname.exe但是,计算器没有我可以杀死的 simple.exe。 The default Windows 10 apps have odd names, and are technically file folders according to their properties.默认的 Windows 10 应用程序具有奇怪的名称,并且根据其属性在技术上是文件夹。

Can somebody help me with how to kill the Windows apps processes via batch (or something else if that's better)?有人可以帮助我了解如何通过批处理(或其他更好的方式)终止 Windows 应用程序进程吗?

Windows Calculator's executable is located (for me) at Windows Calculator的可执行文件(对我来说)位于

C:\\Program Files\\WindowsApps\\Microsoft.WindowsCalculator_10.1611.3123.0_x86__8wekyb3d8bbwe \\calculator.exe

that program is launched by calc.exe . 该程序由calc.exe启动。 You can terminate Windows Calculator with: 您可以使用以下命令终止Windows Calculator:

taskkill /f /im calculator.exe

Instead use Stop-Process -Name calculator而是使用Stop-Process -Name calculator

in my tasklist it appears as CalculatorApp.exe在我的任务列表中它显示为 CalculatorApp.exe

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM