DeleteAce function (securitybaseapi.h)
The DeleteAce function deletes an access control entry (ACE) from an access control list (ACL).
Syntax
BOOL DeleteAce(
[in, out] PACL pAcl,
[in] DWORD dwAceIndex
);
Parameters
[in, out] pAcl
A pointer to an ACL. The ACE specified by the dwAceIndex parameter is removed from this ACL.
[in] dwAceIndex
The ACE to delete. A value of zero corresponds to the first ACE in the ACL, a value of one to the second ACE, and so on.
Return value
If the function succeeds, the function returns nonzero.
If the function fails, the return value is zero. To get extended error information, call GetLastError.
Remarks
An application can use the ACL_SIZE_INFORMATION structure retrieved by the GetAclInformation function to discover the size of the ACL and the number of ACEs it contains. The GetAce function retrieves information about an individual ACE.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows XP [desktop apps | UWP apps] |
Minimum supported server | Windows Server 2003 [desktop apps | UWP apps] |
Target Platform | Windows |
Header | securitybaseapi.h (include Windows.h) |
Library | Advapi32.lib |
DLL | Advapi32.dll |