AudienceRules Property

The AudienceRules property of the Audience class gets an array of AudienceRuleComponent objects that represent rules that define this audience.

Property Value

An ArrayList that contains a list of rules that define this audience. Each item in the list contains the rule operand, operator, and value.

Remarks

If a user adds a new audience rule by calling Audience.AudienceRules.Add directly and then calls the Commit method of the Audience class, the new rule will not be saved. The AudienceRules property must be set before calling the Commit method. The recomended way to avoid this problem is to create a new ArrayList of rules and set Audience.AudienceRules = newArrayListOfRules. Setting AudienceRules in this manner internally sets a flag that indicates to Commit that the rule has been changed since the last Commit. If you call Audience.AudienceRules.Add directly, this internal flag is never set and Commit does not save any changes.

Requirements

Platforms: Microsoft Windows Server 2003

Security: Code Access Security