Compartir a través de


IAccessControl::GrantAccessRights

A version of this page is also available for

Windows Embedded CE 6.0 R3

4/8/2010

This method merges the new ACTRL_ACCESS list with the existing access rights on the object.

Syntax

HRESULT GrantAccessRights(
  PACTRL_ACCESSW pAccessList 
);

Parameters

  • pAccessList
    [in] Pointer to the ACTRL_ACCESSW list, which contains an array of access lists for the object.

Return Value

None.

Remarks

Merging the new ACTRL_ACCESSW list with the existing access rights ensures that the object will have at least the indicated access rights.

This merge process consists of adding the new denied access rights before the old denied access rights, and the new allowed access rights before the existing allowed rights.

None of the existing rights are removed.

Following a merge, the access rights on an object are ordered as follows:

[New Access Denied]

[Old Access Denied]

[New Access Allowed]

[Old Access Allowed]

The system-supplied implementation of GrantAccessRights (CLSID_DCOMAccessControl) requires that the cEntries member of the ACTRL_ACCESSW structure be set to exactly 1.

In addition, the lpProperty member of the ACTRL_PROPERTY_ENTRYW structure must be NULL to indicate that the access entry list applies to the object itself.

To determine whether the platform supports this interface, see Determining Supported COM APIs.

Requirements

Header iaccess.h
Library ole32.lib, uuid.lib
Windows Embedded CE Windows CE 3.0 and later
Windows Mobile Windows Mobile Version 5.0 and later

See Also

Reference

IAccessControl::GetAllAccessRights
IAccessControl::SetAccessRights