IAccessControl::SetAccessRights

Replaces the existing access rights on an object with the specified list.

HRESULT SetAccessRights(
  PACTRL_ACCESSW pAccessList  //Pointer to the access list
);
 

Parameters

pAccessList
[in] Pointer to the ACTRL_ACCESSW list.

Remarks

After its access rights are replaced, an object has only the access rights specified in the ACTRL_ACCESSW list.

Following IAccessControl::SetAccessRights, the access rights on an object are as follows:

[New Access Denied] [New Access Allowed]

The IAccessControl::SetAccessRights method uses the ACTRL_ACCESSW structure, which contains a list of access lists to write to the object. This structure is described in IAccessControl::GrantAccessRights.

QuickInfo

  Windows NT: Use version 4.0 or later.
  Windows: Available as a Windows 95 redistributable.
  Windows CE: Unsupported.
  Header: Declared in oleext.h.

See Also

IAccessControl::GrantAccessRights, IAccessControl::GetAllAccessRights