Registers a service type with the service control manager and the Server service. The Server service can then announce the registered service type as one it currently supports. The NetServerGetInfo and NetServerEnum functions obtain a specified machine's supported service types.
BOOL NET_API_FUNCTION SetServiceBits( IN SERVICE_STATUS_HANDLE hServiceStatus, IN DWORD dwServiceBits, IN BOOL bSetBitsOn, IN BOOL bUpdateImmediately );
A handle to the status information structure for the service. A service obtains the handle by calling the RegisterServiceCtrlHandlerEx function.
The service type.
Certain bit flags (0xC00F3F7B) are reserved for use by Microsoft. The SetServiceBits function fails with the error ERROR_INVALID_DATA if any of these bit flags are set in dwServiceBits. The following bit flags are reserved for use by Microsoft.
Certain bit flags (0x00300084) are defined by Microsoft, but are not specifically reserved for systems software. The following are these bit flags.
Certain bit flags (0x3FC0C000) are not defined by Microsoft, and their use is not coordinated by Microsoft. Developers of applications that use these bits should be aware that other applications can also use them, thus creating a conflict. The following are these bit flags.
If this value is TRUE, the bits in dwServiceBit are to be set. If this value is FALSE, the bits are to be cleared.
If this value is TRUE, the Server service is to perform an immediate update. If this value is FALSE, the update is not be performed immediately.
If the function succeeds, the return value is nonzero.
If the function fails, the return value is zero. To get extended error information, call GetLastError.
|Minimum supported client||Windows XP [desktop apps only]|
|Minimum supported server||Windows Server 2003 [desktop apps only]|