OlRuleConditionType Enumeration

Specifies the type of rule condition or exception condition of a rule.

Namespace:  Microsoft.Office.Interop.Outlook
Assembly:  Microsoft.Office.Interop.Outlook (in Microsoft.Office.Interop.Outlook.dll)

Syntax

'Declaration
Public Enumeration OlRuleConditionType
'Usage
Dim instance As OlRuleConditionType
public enum OlRuleConditionType

Members

Member name Description
olConditionUnknown Unrecognized condition.
olConditionFrom Sender is in the recipient list specified in _ToOrFromRuleCondition.Recipients.
olConditionSubject Subject contains words specified in TextRuleCondition.Text.
olConditionAccount Account is the account specified in _AccountRuleCondition.Account.
olConditionOnlyToMe Message is sent only to me.
olConditionTo My name is in the To box.
olConditionImportance Message is marked with the specified level of importance.
olConditionSensitivity Message is marked with the specified level of sensitivity.
olConditionFlaggedForAction Message is flagged for the specified action.
olConditionCc Message has my name in the Cc box.
olConditionToOrCc Message has my name in the To or Cc box.
olConditionNotTo Message does not have my name in the To box.
olConditionSentTo Sent to recipients (To, Cc) are in the recipient list specified in ToOrFromRuleCondition.Recipients.
olConditionBody Body contains words specified in _TextRuleCondition.Text.
olConditionBodyOrSubject Body or subject contains words specified by TextRuleCondition.Text.
olConditionMessageHeader Message header contains words specified in TextRuleCondition.Text.
olConditionRecipientAddress Recipient address contains words specified in TextRuleCondition.Text.
olConditionSenderAddress Sender address contains words specified in TextRuleCondition.Text.
olConditionCategory Category is the category specified in _CategoryRuleCondition.Categories.
olConditionOOF Message is an out-of-office message.
olConditionHasAttachment Message has one or more attachments.
olConditionSizeRange Message size is between x and y in units of KB, where x and y are Integer values.
olConditionDateRange Message was received between x and y, where x and y are Date values.
olConditionFormName Message uses the form specified in _FormNameRuleCondition.FormName.
olConditionProperty Document property is exactly, contains, or does not contain specified properties.
olConditionSenderInAddressBook Sender is in the address list specified in AddressRuleCondition.Address.
olConditionMeetingInviteOrUpdate Message is a meeting invitation or update.
olConditionLocalMachineOnly Rule can run only on the local machine.
olConditionOtherMachine Rule can run only on a specific machine that is not the current machine.
olConditionAnyCategory Message is assigned to any category.
olConditionFromRssFeed Message is generated from a specific RSS subscription.
olConditionFromAnyRssFeed Message is generated from any RSS subscription.

Remarks

The list of rule condition types in this enumeration includes all the rule conditions and exception conditions that the Rules and Alerts Wizard supports. Note that while you can programmatically enumerate all the rule conditions and exception conditions for a rule, you can programmatically create a rule with only the most commonly used conditions. For more information, see Specifying Rule Conditions.

For example, the rule condition types olConditionDateRange and olConditionSizeRange are supported only for enumeration and enabling or disabling in an existing rule. You cannot programmatically create a rule with such conditions. You cannot programmatically get or set the values of x and y that represent the range.

See Also

Reference

Microsoft.Office.Interop.Outlook Namespace

Other Resources

How to: Execute a Rule on a Local Computer