网站首页  词典首页

请输入您要查询的函数:

 

术语 deleteprinter
释义 DeletePrinter
语法:
BOOL DeletePrinter(
__inout HANDLE hPrinter
);
DeletePrinter功能
该DeletePrinter函数删除指定的打印机对象。
参数
hPrinter [ in , out ]
句柄打印机对象,将被删除。使用OpenPrinter或添加打印机函数检索打印机处理。
返回值
如果函数成功,返回值是一个非零值。
如果函数失败,返回值是零。
备注
如果有剩余的打印作业必须为指定的打印机处理,DeletePrinter标志着为待删除的打印机,然后删除它时,所有的打印作业,共印了。没有打印作业可以被添加到一个正在等待标记为删除打印机。
打印机标记为删除之前不能举行,但它的打印作业能够举行,恢复,并重新启动。如果打印机是举行有打印机的工作,DeletePrinter失败,ERROR_ACCESS_DENIED。
请注意,DeletePrinter不关闭句柄传递给它。因此,应用程序必须仍然要求ClosePrinter。
要求:
最低支持:client-Windows 2000专业版
最低支持server-Windows 2000服务器
HeaderWinspool.h(头文件:winuser.h)
LibraryWinspool.lib
参见
Printing and Print Spooler Overview
Printing and Print Spooler 函数
添加打印机
EnumPrinters
OpenPrinter
如果有任何问题和意见,请发送给微软(wsddocfb@microsoft.com)
生成日期:2009年7月11日
==英文原文==DeletePrinter Function
The DeletePrinter function deletes the specified printer object.
Syntax
BOOL DeletePrinter(
__inout HANDLE hPrinter
);
Parameters
hPrinter [in, out]
Handle to a printer object that will be deleted. Use the OpenPrinter or AddPrinter function to retrieve a printer handle.
Return Value
If the function succeeds, the return value is a nonzero value.
If the function fails, the return value is zero.
Remarks
If there are print jobs remaining to be processed for the specified printer, DeletePrinter marks the printer for pending deletion, and then deletes it when all the print jobs have been printed. No print jobs can be added to a printer that is marked for pending deletion.
A printer marked for pending deletion cannot be held, but its print jobs can be held, resumed, and restarted. If the printer is held and there are jobs for the printer, DeletePrinter fails with ERROR_ACCESS_DENIED.
Note that DeletePrinter does not close the handle that is passed to it. Thus, the application must still call ClosePrinter .
Requirements
Minimum supported clientWindows 2000 Professional
Minimum supported serverWindows 2000 Server
HeaderWinspool.h (include Windows.h)
LibraryWinspool.lib
See Also
Printing and Print Spooler Overview
Printing and Print Spooler Functions
AddPrinter
EnumPrinters
OpenPrinter
Send comments about this topic to Microsoft
Build date: 7/11/2009
==原始网址==http://msdn.microsoft.com/en-us/library/dd183541(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:30:39