IAdmInactiveAccountCondition
The IAdmInactiveAccountCondition interface represents the If is inactive <period> condition.
Inheritance: IAdmCondition
Properties
-
Property
-
Description
-
PeriodOperator
-
Gets or sets the comparison operator for the condition.
-
PeriodValue
-
Gets or sets the inactive period value.
Details
PeriodOperator
Gets or sets the comparison operator for the condition.
- Type:
- ADM_PERIODCOMPARISONOPERATOR_ENUM
- Access:
- Read/Write
PeriodValue
Gets or sets the inactive period value.
- Type:
- int
- Access:
- Read/Write
Examples
The following code sample creates a condition that returns true if the account has been inactive for more than 3 weeks.
- PowerShell
-
# The $actionSet variable refers to an action set in a # business rule, custom command, or scheduled task. # Create condition. $condition = $actionSet.Conditions.CreateEx("adm-InactiveAccountCondition") $inactivityCondition = $condition.GetCondition() $inactivityCondition.PeriodOperator = "ADM_EXPIRATIONCOMPARISONOPERATOR_MORETHAN" $inactivityCondition.PeriodValue = 3 # Save changes. $condition.SetCondition($inactivityCondition) $condition.SetInfo() $actionSet.Conditions.Add($condition) - C#
-
// The actionSet variable refers to an action set in a // business rule, custom command, or scheduled task. // Create condition. IAdmBusinessRuleCondition condition = (IAdmBusinessRuleCondition)actionSet.Conditions.CreateEx( "adm-InactiveAccountCondition"); IAdmInactiveAccountCondition inactivityCondition = (IAdmInactiveAccountCondition)condition.GetCondition(); inactivityCondition.PeriodOperator = ADM_EXPIRATIONCOMPARISONOPERATOR_ENUM.ADM_EXPIRATIONCOMPARISONOPERATOR_MORETHAN; inactivityCondition.PeriodValue = 3; // Save changes. condition.SetCondition(inactivityCondition); condition.SetInfo(); actionSet.Conditions.Add(condition);
Requirements
Minimum required version: 2011.3