网站首页  词典首页

请输入您要查询的函数:

 

术语 abortsystemshutdown
释义 AbortSystemShutdown
语法:
C++
BOOL WINAPI AbortSystemShutdown(
__in_opt LPTSTR lpMachineName
);
AbortSystemShutdown功能
在指定机器上取消正在执行的关闭操作。
参数
lpMachineName [中,可选]
计算机的网络名称关机是要加以制止。如果lpMachineName为NULL或空字符串,该函数停止在本地计算机上关闭。
返回值
如果函数成功,返回值为非零。
如果函数失败,返回值是零。为了获得更多错误信息,调用GetLastError。
备注
在InitiateSystemShutdown和InitiateSystemShutdownEx功能显示一个对话框,通知用户系统正在关闭。在关机超时期间,AbortSystemShutdown功能,可以防止关闭系统。
Windows Server 2003和SP1的Windows XP:如果计算机是关闭终端服务的服务器,系统会显示一个对话框,所有本地和远程用户警告他们说,已经开始关闭。如果关机是由AbortSystemShutdown预防,系统会显示对话框的用户,通知他们该服务器不再关闭。
若要停止关闭,调用进程必须有SE_SHUTDOWN_NAME特权本地计算机。若要停止关闭,调用进程必须具有远程计算机上SE_REMOTE_SHUTDOWN_NAME特权远程计算机。默认情况下,用户可以使他们对所登录到计算机SE_SHUTDOWN_NAME特权,管理员可以启用远程计算机上的SE_REMOTE_SHUTDOWN_NAME特权。有关更多信息,请运行特权。
失败的常见原因包括一个无效的计算机的名称,不可访问的计算机,或不充分的特权。
实例
有关示例,请参见显示关机对话框中。
要求:
最低支持:client-Windows 2000专业版
最低支持server-Windows 2000服务器
HeaderWinreg.h(头文件:winuser.h)
LibraryAdvapi32.lib
DLLAdvapi32.dll
Unicode和ANSI namesAbortSystemShutdownW(Unicode)和AbortSystemShutdownA(ANSI)的
参见
关机
系统关机函数
InitiateSystemShutdown
如果有任何问题和意见,请发送给微软(wsddocfb@microsoft.com)
生成日期:2009年7月30日
==英文原文==AbortSystemShutdown Function
Stops a system shutdown that has been initiated.
Syntax
C++
BOOL WINAPI AbortSystemShutdown(
__in_opt LPTSTR lpMachineName
);
Parameters
lpMachineName [in, optional]
The network name of the computer where the shutdown is to be stopped. If lpMachineName is NULL or an empty string, the function stops the shutdown on the local computer.
Return Value
If the function succeeds, the return value is nonzero.
If the function fails, the return value is zero. To get extended error information, call GetLastError .
Remarks
The InitiateSystemShutdown and InitiateSystemShutdownEx functions display a dialog box that notifies the user that the system is shutting down. During the shutdown time-out period, the AbortSystemShutdown function can prevent the system from shutting down.
Windows Server 2003 and Windows XP with SP1: If the computer to be shut down is a Terminal Services server, the system displays a dialog box to all local and remote users warning them that shutdown has been initiated. If shutdown is prevented by AbortSystemShutdown, the system displays dialog box to the users informing them that the server is no longer shutting down.
To stop the local computer from shutting down, the calling process must have the SE_SHUTDOWN_NAME privilege. To stop a remote computer from shutting down, the calling process must have the SE_REMOTE_SHUTDOWN_NAME privilege on the remote computer. By default, users can enable the SE_SHUTDOWN_NAME privilege on the computer they are logged onto, and administrators can enable the SE_REMOTE_SHUTDOWN_NAME privilege on remote computers. For more information, see Running with Special Privileges .
Common reasons for failure include an invalid computer name, an inaccessible computer, or insufficient privilege.
Examples
For an example, see Displaying the Shutdown Dialog Box .
Requirements
Minimum supported clientWindows 2000 Professional
Minimum supported serverWindows 2000 Server
HeaderWinreg.h (include Windows.h)
LibraryAdvapi32.lib
DLLAdvapi32.dll
Unicode and ANSI namesAbortSystemShutdownW (Unicode) and AbortSystemShutdownA (ANSI)
See Also
Shutting Down
System Shutdown Functions
InitiateSystemShutdown
Send comments about this topic to Microsoft
Build date: 7/30/2009
==原始网址==http://msdn.microsoft.com/en-us/library/aa376630(VS.85).aspx\n
随便看

 

windows api函数参考手册包含2258条windows api函数文档,详细介绍nodejs、java、rust调用windows api的方法技巧,是学习windows api编程的入门中文文档。

 

Copyright © 2004-2023 Winrtm.com All Rights Reserved
京ICP备2021023879号-40 更新时间:2024/10/6 11:25:24