New to Telerik ReportingStart a free 30-day trial

Represents a collection of StyleRule objects.

Definition

Namespace:Telerik.Reporting.Drawing

Assembly:Telerik.Reporting.dll

Syntax:

C#
[TypeConverter("Telerik.Reporting.Design.StyleRuleCollectionConverter, Telerik.Reporting.Design, Version=20.1.26.615, Culture=neutral, PublicKeyToken=a9d7983dfcc261be")]
public class StyleRuleCollection : Collection<StyleRule>

Inheritance: objectCollection<StyleRule>StyleRuleCollection

Derived Classes: StyleSheet

Constructors

Initializes a new instance of the StyleRuleCollection class.

C#
public StyleRuleCollection()

Initializes a new instance of the

C#
public StyleRuleCollection(StyleRule[] rules)
Parameters:rulesStyleRule[]

The initial StyleRule objects that belong to the collection.

Methods

Adds an array of style rule objects to the collection.

C#
public void AddRange(StyleRule[] rules)
Parameters:rulesStyleRule[]

An array of StyleRule objects to add to the collection.

Remarks:

The StyleRule objects contained in the rules array are appended to the end of the collection.

You can use the AddRange method to quickly add a group of StyleRule objects to the collection instead of manually adding each StyleRule to the collection using the Add(T) method.

To remove a StyleRule that you previously added, use the Remove(T), RemoveAt(int), or Clear() methods.