我已经看过这篇文章:如何通过 C++ 启动 explorer.exe?这是一个旧帖子。我在玩批处理文件命令,我想用 C++ 复制这个函数
taskkill /f /im explorer.exe
start explorer.exe
我正在使用
系统(” ”)
C++ 中的命令来实现它。这是代码:注意,杀死 explorer.exe 正在工作,但我无法再次启动它。
#include "pch.h"
#include <windows.h>
#include <iostream>
int main ()
{
system("taskkill /f /im explorer.exe");
system("explorer.exe");
}
它不是打开 explorer.exe 来恢复 windows UI,而是在 windows 中打开快速访问。任何想法?