TaskSecuritySetAccessRule Method

Removes all access control rules with the same user and AccessControlType (allow or deny) as the specified rule, and then adds the specified rule.

Definition

Namespace: Microsoft.Win32.TaskScheduler
Assembly: Microsoft.Win32.TaskScheduler (in Microsoft.Win32.TaskScheduler.dll) Version: 2.11.0
public void SetAccessRule(
	TaskAccessRule rule
)

Parameters

rule  TaskAccessRule
The TaskAccessRule to add. The user and AccessControlType of this rule determine the rules to remove before this rule is added.

See Also