From:	SMTP%"davet@altatech.com"  7-NOV-1997 17:01:46.83
To:	James McNabb <jmcnabb@cstone.net>
CC:	
Subj:	Re: [ntdev] Reboot by command

Return-Path: owner-ntdev@atria.com
Received: by arisia.gce.com (UCX V4.1-12C, OpenVMS V7.1 VAX);
	Fri, 7 Nov 1997 16:43:37 -0500
Received: from gw.atria.com (gw.atria.com [192.88.237.2]) by mercury.mv.net (8.8.8/mem-971025) with SMTP id XAA15385 for <everhart@arisia.gce.com>; Tue, 4 Nov 1997 23:22:47 -0500 (EST)
Received: by gw.atria.com id <SAA11119@gw.atria.com> Tue, 4 Nov 1997 18:56:00 -0500    
Received: from altatech.com by gw.atria.com id <SAA11060@gw.atria.com> Tue, 4 Nov 1997 18:55:50 -0500    
Received: from alta.altatech.com (alta [198.60.83.200]) by altatech.com (8.8.3/8.8.3) with ESMTP id QAA05982; Tue, 4 Nov 1997 16:55:26 -0700
Received: from ALTA/SpoolDir by alta.altatech.com (Mercury 1.21);
    4 Nov 97 17:51:29 MDT
Received: from SpoolDir by ALTA (Mercury 1.21); 4 Nov 97 17:51:18 MDT
Received: from littlec by alta.altatech.com (Mercury 1.21);
    4 Nov 97 17:51:15 MDT
Message-ID: <3436D771.7541@altatech.com>
Date: Sat, 04 Oct 1997 17:55:29 -0600
From: David Tucker <davet@altatech.com>
Organization: Alta Technology
X-Mailer: Mozilla 3.03 (WinNT; I)
MIME-Version: 1.0
To: James McNabb <jmcnabb@cstone.net>
CC: ntdev@atria.com
Subject: Re: [ntdev] Reboot by command
References: <19971104223200.AAA6489@Dialin184.cstone.net>
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Sender: owner-ntdev@atria.com
Precedence: bulk

I've used this in a simple console app.  It worked for me.

BOOL InitiateSystemShutdown(
    LPTSTR lpMachineName,	// address of name of computer to shut down  
    LPTSTR lpMessage,	// address of message to display in dialog box 
    DWORD dwTimeout,	// time to display dialog box 
    BOOL bForceAppsClosed,	// force applications with unsaved changes
flag 
    BOOL bRebootAfterShutdown 	// reboot flag 
   );	



James McNabb wrote:
> 
> How can I reboot an NT workstation from the command prompt?
> Is there a single command to do this?
> 
> A command....not CTRL-ALT-DEL.... :-)
> 
> James McNabb
> jmcnabb@cstone.net
> Network Xpress Inc.
> 
>  - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
> [ To unsubscribe, send email to ntdev-request@atria.com with body
> UNSUBSCRIBE (the subject is ignored). ]
 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
[ To unsubscribe, send email to ntdev-request@atria.com with body
UNSUBSCRIBE (the subject is ignored). ]
