The SetResourceStatus function is called to update the status of a resource.
VOID WINAPI SetResourceStatus(
RESOURCE_HANDLE ResourceHandle,
PRESOURCE_STATUS ResourceStatus
);
None.
Resource DLLs call SetResourceStatus to update the status of a resource after their Online or Offline entry point function has returned ERROR_IO_PENDING. It should not be called at any other time. A pointer to the function is passed to the resource's implementation of Startup.
SetResourceStatus is implemented by the Resource Monitor and is similar to the SetServiceStatus function for Win32 services.
Update the current state of a resource whenever necessary after you have returned ERROR_IO_PENDING. If the resource is in one of the pending states, increment the values for the CheckPoint and WaitHint members of the RESOURCE_STATUS structure and set the ResourceState member to ClusterResourceOnlinePending or ClusterResourceOfflinePending before you begin calling SetResourceStatus. Call SetResourceStatus until one of the following two situations occurs:
There is no need to call SetResourceStatus to set the state of a resource to a pending state because the Resource Monitor automatically sets it to the appropriate pending state whenever Online or Offline returns ERROR_IO_PENDING.
Version: Use Windows NT Server Enterprise Edition 4.0.
Windows CE: Unsupported.
Header: Declared in resapi.h.