Export (0) Print
Expand All
Expand Minimize

WPUGetProviderPath function

The WPUGetProviderPath function retrieves the DLL path for the specified provider.

Syntax


int WPUGetProviderPath(
  _In_    LPGUID lpProviderId,
  _Out_   LPWSTR lpszProviderDllPath,
  _Inout_ LPINT  lpProviderDllPathLen,
  _Out_   LPINT  lpErrno
);

Parameters

lpProviderId [in]

Locally unique identifier of the provider. This must be a value obtained by using WSCEnumProtocols.

lpszProviderDllPath [out]

Pointer to a buffer containing a string that identifies the provider DLL's path. This path is a null-terminated string and any embedded environment strings (such as %SystemRoot%) have not been expanded.

lpProviderDllPathLen [in, out]

Size of the buffer pointed to by lpszProviderDllPath, in characters.

lpErrno [out]

Pointer to the error code.

Return value

If no error occurs, WPUGetProviderPath returns zero. Otherwise, it returns SOCKET_ERROR, and a specific error code is available in lpErrno.

Error codeMeaning
WSAEINVAL

The lpProviderId parameter does not specify a valid provider.

WSAEFAULT

Either lpszProviderDllPath or lpErrno is not in a valid part of the user address space, or lpProviderDllPathLen is too small.

 

Remarks

The WPUGetProviderPath function retrieves the DLL path for the specified provider. The DLL path is null-terminated and may contain embedded environment strings (such as %SystemRoot%). Thus, the string should be expanded prior to being used with LoadLibrary. For more information, see LoadLibrary.

Requirements

Minimum supported client

Windows 2000 Professional [desktop apps only]

Minimum supported server

Windows 2000 Server [desktop apps only]

Header

Ws2spi.h

See also

WSCInstallProvider
WSCEnumProtocols

 

 

Community Additions

ADD
Show:
© 2015 Microsoft