如何关闭所有正在运行的窗口? [英] How to close all the running windows?

查看:120
本文介绍了如何关闭所有正在运行的窗口?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我要关闭所有正在运行的窗口,该怎么做?谢谢.

I want to close all the running windows, how to do this? Thank you.

推荐答案

您可以尝试使用EnumWindows枚举所有窗口,然后使用SendMessage向其发送WM_CLOSE消息.
忽略WM_CLOSE消息的Windows仍无法关闭.
You could try enumerating all windows using EnumWindows and then send it the WM_CLOSE message using SendMessage.
Windows that ignore the WM_CLOSE message would still not close.


请参阅此文章


感谢pguimalan和_Superman_,但是我需要关闭正在运行的窗口中的 all ,而不是应用程序(窗口).谢谢.请帮助我.
Thank pguimalan and _Superman_, but I need close all the running windows, not an app (window). Thank. Please help me.


这篇关于如何关闭所有正在运行的窗口?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆