NSPRemoveServiceClass function

The NSPRemoveServiceClass function permanently removes a specified service class from the namespace.

Syntax


int WSAAPI NSPRemoveServiceClass(
  _In_ LPGUID lpProviderId,
  _In_ LPGUID lpServiceClassId
);

Parameters

lpProviderId [in]

A pointer to the GUID of the specific namespace provider that this service class schema is to be removed from.

lpServiceClassId [in]

A pointer to the GUID for the service class to remove.

Return value

The function should return NO_ERROR (zero) if the routine succeeds. It should return SOCKET_ERROR (–1) if the routine fails and it must set the appropriate error code using WSASetLastError.

Error codeMeaning
WSA_NOT_ENOUGH_MEMORY

There is not enough memory available to perform this operation.

WSA_INVALID_PARAMETER

The specified GUID was not valid.

WSAEACCES

The calling routine does not have sufficient privileges to remove the Service.

WSAEINVAL

The specified service class identifier GUID was not valid.

WSAEOPNOTSUPP

The operation is not supported. This error is returned if the namespace provider does not implement this function.

WSATYPE_NOT_FOUND

The specified class was not found in any of the namespaces.

 

Requirements

Minimum supported client

Windows 2000 Professional [desktop apps only]

Minimum supported server

Windows 2000 Server [desktop apps only]

Header

Ws2spi.h

See also

WSASetLastError

 

 

Show: