• 0

[VB][C++] shell()


Question

in vb theres a function shell() which executes command line instructions im just wondering if theres a smimilar funcion in c++/Win32

and whats the command line instruction to shut down the workstaqtion is it

rundll32.exe user32.dll shutdownworkstation

Link to comment
Share on other sites

4 answers to this question

Recommended Posts

  • 0

ShellExecute or ShellExecuteEx

I don't see ShutdownWorkstation in user32.dll. The only way I know of doing it is with either ExitWindowsEx, or InitiateSystemShutdown. I believe that the preferred way is InitiateSystemShutdown as it gives the user a chance to abort by showing the dialog.

Link to comment
Share on other sites

This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.