Win32隐藏输出console窗口时间:2023-03-08 22:11:17 #include <Windows.h> void HideConsole() { ::ShowWindow(::GetConsoleWindow(), SW_HIDE); } void ShowConsole() { ::ShowWindow(::GetConsoleWindow(), SW_SHOW); } bool IsConsoleVisible() { return (::IsWindowVisible(::GetConsoleWindow()) != FALSE); }