>bool closecomputer(int kind)% T' m7 K# A( _& e* p
> // Get a token for this process.
> // Get the LUID for the shutdown privilege.
> tkp.PrivilegeCount = 1; // one privilege to set7 E5 }4 a, ]% d8 e! }7 N
> // Get the shutdown privilege for this process.
> if (GetLastError() != ERROR_SUCCESS)6 K% i; `$ _7 @; Q: P( I0 C$ z
>}</P>
| 欢迎光临 数学建模社区-数学中国 (http://www.madio.net/) | Powered by Discuz! X2.5 |