自动隐藏任务栏图标(TaskBar)
ShowWindow( Application.Handle, SW_HIDE );
SetWindowLong( Application.Handle, GWL_EXSTYLE,
GetWindowLong(Application.Handle, GWL_EXSTYLE) or
WS_EX_TOOLWINDOW and not WS_EX_APPWINDOW);
ShowWindow( Application.Handle, SW_SHOW );
讓使用者按下 Ctrl+Alt+Del 鍵時不會被顯示出來
function RegisterServiceProcess(dwProcessID, dwType: Integer): Integer; stdcall; external 'KERNEL32.DLL';
隐藏:
RegisterServiceProcess(GetCurrentProcessID, 1);
复现:
RegisterServiceProcess(GetCurrentProcessID, 0);