网站首页  词典首页

请输入您要查询的函数:

 

术语 wnetgetlasterror
释义 WNetGetLastError
语法:
C++
DWORD WNetGetLastError(
__out LPDWORD lpError,
__out LPTSTR lpErrorBuf,
__in DWORD nErrorBufSize,
__out LPTSTR lpNameBuf,
__in DWORD nNameBufSize
);
WNetGetLastError功能
该WNetGetLastError函数检索最新的扩展错误代码1 WNet的功能集。该网络供应商举报此错误代码,它不会一般的错误之一Winerror.h中SDK头文件中。
参数
lpError [out]
指针变量,它接收错误代码的网络供应商报告。错误代码是特定于网络提供商。
lpErrorBuf [out]
缓冲区指针接收空结尾的字符串描述错误的。
nErrorBufSize [in]
缓冲区的大小指向的lpErrorBuf参数,以字符。如果缓冲区的内容过于小错误字符串,该字符串被截断,但仍然空终止。为最少256个字符缓冲区的建议。
lpNameBuf [out]
缓冲区指针接收空结尾的字符串识别网络供应商,提高了错误。
nNameBufSize [in]
缓冲区的大小指向的lpNameBuf参数,以字符。如果缓冲区的内容过于小错误字符串,该字符串被截断,但仍然空终止。
返回值
如果函数成功,并获得了最后一个错误,网络提供商报道,返回值为NO_ERROR。
如果调用方提供一个无效的缓冲区,则返回值为ERROR_INVALID_ADDRESS。
备注
该WNetGetLastError函数检索错误所特有的网络提供商。您可以调用WNetGetLastError当WNet函数返回ERROR_EXTENDED_ERROR。
GetLastError函数一样,WNetGetLastError返回扩展的错误信息,这是对每个线程的维修保养。与GetLastError函数,该函数可以返回WNetGetLastError报告是没有任何现有的Winerror.h中描述的错误,错误代码字符串。
有关使用应用程序的信息定义的错误处理程序调用WNetGetLastError功能,请参见检索网络错误。
要求:
最低支持:client-Windows 2000专业版
最低支持server-Windows 2000服务器
HeaderWinnetwk.h
LibraryMpr.lib
DLLMpr.dll
Unicode和ANSI namesWNetGetLastErrorW(Unicode)和WNetGetLastErrorA(ANSI)的
参见
Windows网络(WNet)概述
Windows网络函数
如果有任何问题和意见,请发送给微软(wsddocfb@microsoft.com)
生成日期:2009年8月6日
==英文原文==WNetGetLastError Function
The WNetGetLastError function retrieves the most recent extended error code set by a WNet function. The network provider reported this error code; it will not generally be one of the errors included in the SDK header file WinError.h.
Syntax
C++
DWORD WNetGetLastError(
__out LPDWORD lpError,
__out LPTSTR lpErrorBuf,
__in DWORD nErrorBufSize,
__out LPTSTR lpNameBuf,
__in DWORD nNameBufSize
);
Parameters
lpError [out]
Pointer to a variable that receives the error code reported by the network provider. The error code is specific to the network provider.
lpErrorBuf [out]
Pointer to the buffer that receives the null-terminated string describing the error.
nErrorBufSize [in]
Size of the buffer pointed to by the lpErrorBuf parameter, in characters. If the buffer is too small for the error string, the string is truncated but still null-terminated. A buffer of at least 256 characters is recommended.
lpNameBuf [out]
Pointer to the buffer that receives the null-terminated string identifying the network provider that raised the error.
nNameBufSize [in]
Size of the buffer pointed to by the lpNameBuf parameter, in characters. If the buffer is too small for the error string, the string is truncated but still null-terminated.
Return Value
If the function succeeds, and it obtains the last error that the network provider reported, the return value is NO_ERROR.
If the caller supplies an invalid buffer, the return value is ERROR_INVALID_ADDRESS.
Remarks
The WNetGetLastError function retrieves errors that are specific to a network provider. You can call WNetGetLastError when a WNet function returns ERROR_EXTENDED_ERROR.
Like the GetLastError function, WNetGetLastError returns extended error information, which is maintained on a per-thread basis. Unlike GetLastError, the WNetGetLastError function can return a string for reporting errors that are not described by any existing error code in WinError.h.
For more information about using an application-defined error handler that calls the WNetGetLastError function, see Retrieving Network Errors .
Requirements
Minimum supported clientWindows 2000 Professional
Minimum supported serverWindows 2000 Server
HeaderWinnetwk.h
LibraryMpr.lib
DLLMpr.dll
Unicode and ANSI namesWNetGetLastErrorW (Unicode) and WNetGetLastErrorA (ANSI)
See Also
Windows Networking (WNet) Overview
Windows Networking Functions
Send comments about this topic to Microsoft
Build date: 8/6/2009
==原始网址==http://msdn.microsoft.com/en-us/library/aa385459(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:29:04