CreateProcess启动隐藏的外部程序

HDESK hDesk = CreateDesktop(_T("MyDesk"), NULL, NULL, 0, GENERIC_ALL, NULL); ASSERT(hDesk); STARTUPINFO si = {sizeof(si)}; si.lpDesktop = _T("MyDesk"); si.dwFlags = STARTF_USESHOWWINDOW; si.wShowWindow = SW_HIDE; PROCESS_INFORMATION pi = {0}; TCHAR szApp[MAX_PATH] = {_T("F://11.exe")}; if(CreateProcess(NULL, szApp, NULL, NULL, FALSE, 0, NULL, NULL, &si, &pi)) { CloseHandle(pi.hThread); CloseHandle(pi.hProcess); }

你可能感兴趣的:(null,Path)