Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Question on reboot and shutdown

Posted on 1998-12-02
4
228 Views
Last Modified: 2013-11-20
Hi there,
         Which MFC programming function can i use to perform reboot and shutdown operation of a pc? I'm using MSVC 6.0 to write programs.

Any help offered is very much appreciated!!!
0
Comment
Question by:justinng
  • 2
  • 2
4 Comments
 
LVL 1

Accepted Solution

by:
Bridge earned 20 total points
ID: 1325649
ExitWindowsEx
0
 

Author Comment

by:justinng
ID: 1325650
can u pls elaborate a little more abt it? what are the parameters which are passed to it? That function is for reboot only... what abt shutdown?
0
 
LVL 1

Expert Comment

by:Bridge
ID: 1325651
Look at the help.
The function works for both using EWX_LOGOFF and EWX_REBOOT as parameters.
Windows 9x should be fine but if your running under NT then you will have to adjust the user privialages to do these operations.

And that my friend is another question.
0
 

Author Comment

by:justinng
ID: 1325652
Thanks... I'm only interested in win9x anyway.... :)
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Define unique primary key 9 95
while loop over for loop 7 115
pre4 challenge 19 103
Bartender label printing - switch on and off graphics 3 54
This is to be the first in a series of articles demonstrating the development of a complete windows based application using the MFC classes.  I’ll try to keep each article focused on one (or a couple) of the tasks that one may meet.   Introductio…
Introduction: The undo support, implementing a stack. Continuing from the eigth article about sudoku.   We need a mechanism to keep track of the digits entered so as to implement an undo mechanism.  This should be a ‘Last In First Out’ collec…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question