NSPRemoveServiceClass

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

int NSPRemoveServiceClass (
  IN    LPGUID lpProviderId,   
  IN    LPGUID lpServiceClassId   
);
 

Parameters

lpProviderId
[in] Pointer to the GUID of the specific name space provider that this service class schema is to be removed from.
lpServiceClassId
[in] Pointer to the GUID for the service class to remove.

Return Values

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 SetLastError.

Error Codes

WSATYPE_NOT_FOUND The specified class was not found in any of the name spaces.
WSAEACCES The calling routine does not have sufficient privileges to remove the Service.
WSA_INVALID_PARAMETER The specified GUID was not valid.
WSAEINVAL The specified service class Id GUID was not valid.
WSA_NOT_ENOUGH_MEMORY Not enough free memory available to perform this operation.

QuickInfo

  Windows NT: Yes
  Windows: Yes
  Windows CE: Unsupported.
  Header: Declared in ws2spi.h.