I_IrmPolicyInfo.HrGetListGuid Method

This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This page may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.

Gets the GUID of the document library in which the requested document is located.

HRESULT HrGetListGuid(
    BSTR*  pbstrListGuid



[out] The GUID of the document library in which the requested document is located.

Return Value

All I_IrmPolicyInfo Class methods return HRESULT values. A positive OK value indicates that the operation was successful. A negative return value indicates that the function did not succeed.

In general, if an I_IrmPolicyInfo Class method fails, the protector will not be able to recover from the error and will fail as well.


Because Windows SharePoint Services requires that the I_IrmProtector.HrUnprotect Method method of the autonomous protector provide the document library GUID when called, the I_IrmProtector.HrProtect Method method should store this document library GUID inside the rights-managed file itself.

In the case of integrated Information Rights Management (IRM) protectors, the document library GUID is stored in the metadata property bag associated with the document’s issuance license, which in turn is stored in the document itself. We recommend that you implement a similar approach for autonomous protectors.

Windows SharePoint Services requires the document library GUID from the I_IrmProtector.HrUnprotect Method method to determine if the rights-managed document is being uploaded to the same document library from which it was downloaded. Because rights management is set at the document library level, this helps ensure that users retain the appropriate rights permissions to a file.

For more information on integrated and autonomous protectors, see Custom IRM Protectors.

See Also


I_IrmProtector Interface

I_IrmPolicyInfo Class


Information Rights Management in Windows SharePoint Services Overview

Custom IRM Protectors