Export (0) Print
Expand All

OpenClusterResource function

Opens a resource and returns a handle to it. The PCLUSAPI_OPEN_CLUSTER_RESOURCE type defines a pointer to this function.

Syntax


HRESOURCE WINAPI OpenClusterResource(
  _In_  HCLUSTER hCluster,
  _In_  LPCWSTR lpszResourceName
);

typedef HRESOURCE (WINAPI *PCLUSAPI_OPEN_CLUSTER_RESOURCE)(
    _In_  HCLUSTER hCluster,
    _In_  LPCWSTR lpszResourceName
);

Parameters

hCluster [in]

Handle to a cluster.

lpszResourceName [in]

Pointer to a null-terminated Unicode string containing the name of the resource to be opened.

Resource names are not case sensitive. A resource name must be unique within the cluster. The name is set when the resource is created and can be changed using the SetClusterResourceName function.

Return value

If the operation was successful, OpenClusterResource returns a handle to the opened resource.

Return codeDescription
NULL

The operation was not successful. For information about the error, call the function GetLastError.

 

Examples

See Using Object Handles.

Requirements

Minimum supported client

None supported

Minimum supported server

Windows Server 2003 Enterprise, Windows Server 2003 Datacenter

Header

ClusAPI.h

Library

ClusAPI.lib

DLL

ClusAPI.dll

See also

Failover Cluster Resource Management Functions
CloseClusterResource
OpenClusterResourceEx

 

 

Show:
© 2014 Microsoft