UpdateData(TRUE); SHELLEXECUTEINFOA sei; memset(&sei, 0, sizeof SHELLEXECUTEINFOA); sei.cbSize = sizeof SHELLEXECUTEINFOA; sei.fMask = SEE_MASK_NOCLOSEPROCESS /*| SEE_MASK_FLAG_NO_UI*/; sei.lpVerb = "runas"; sei.lpDirectory = GetModulePath(); sei.lpFile = "curl.exe"; sei.lpParameters = m_strCmd; //MessageBox(m_strCmd, _T("tip"), MB_OK); sei.nShow = SW_SHOW; if (!ShellExecuteExA(&sei)) { CString strLog; strLog.Format(_T("启动curl失败(code:0x%x)"), GetLastError()); MessageBox(strLog); return; }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)