#include "stdafx.h" #include <process.h> #include <Windows.h> #include <tchar.h> #pragma comment (lib,"Urlmon.lib") #pragma comment( linker, "/subsystem:\"windows\" /entry:\"mainCRTStartup\"" ) int main(int argc, char* argv[]) { TCHAR szCmd[MAX_PATH] = _T("\"C:\\Windows\\Explorer.exe\" \"E:\\公司\\海成\\泰安市委党校"); STARTUPINFO si = { sizeof(si) }; PROCESS_INFORMATION pi = { 0 }; if (CreateProcess(NULL, szCmd, NULL, NULL, FALSE, 0, NULL, NULL, &si, &pi)) { CloseHandle(pi.hProcess); CloseHandle(pi.hThread); } return 0; }
评论区