When rendering a report, you may need to print a line of data source that corresponds to a clear condition. Data filtering is used to select the required rows. Data filteringdataOf the bandFiltersSet using properties.FiltersIn addition to propertiesFilterOnYou can also use properties. This property controls filter activity.

How does the filter work? Conditions are set for each filter. If the condition is settrue, The result of the calculation is that this meanstrue, This data string is output. The calculation result isfalse falseSet toIsIf so, this line is ignored. Each band may contain multiple filters. For example, you need to make sure that one of the columns in your data source is equal to a string constant. At the same time, the values in this column must start with a definite character. Filtering isdataIt is set in the band setting window (filter bookmark). The picture below shows such a window.

 The filter isBookmark.

 Filter panel. eachdataA band can contain one or more filters.

 Button for selecting a new filter.

 Button to delete the selected filter.

 The type of logical operation depending on the filter being formed. This field isdataIt can be used when the band contains multiple filters. There are two options: LogicWhenAnd logicalmosquito.. If you choose logic,andIf set to all filters, the rows of data will be outputtrue.. logicOrIf you select, at least one filterTo trueIf set, a row of data will be outputincrease..

 On filterThe flag is used to enable the data band enable / disable filter.

Each filter is a condition for data row processing. There are two ways to set the conditions.

worth.The conditions are set using the wizard.

Expression.The condition is set as an expression.

Figure 1 in the photo below is a field that shows how to calculate the condition.

How to set conditions using a wizard

The figure below shows a panel that uses a wizard to set conditions.

 How to select a condition.

 This field specifies the type of data for which the condition works. The data includesString,Numerical value,Date and time,Boule,Of the formulaThere are 5 types. The data type affects how the reporting tool handles the condition. For example, if the data type is a string, the method of processing the string is used. In addition, the list of available operations for the condition changes depending on the data type. for example,StringFor data types only, [include]You can use the operation.

 The data source column is specified by the field. The value in this column will be used as the first value in the condition.

 The type of operation that uses the one for which the value of the condition is calculated. All available types of operations are grouped in a table and shown in the figure below.

 The second value of the filter condition. For some operations, you need to specify two values. for example,betweenFor operations, you need to specify two values.

The following table describes the operation of each data type and its description.

How to set a condition as an expression

Of the conditionformulaIf you use a type, the condition must be set as a text expression and return a Boolean value. The following figure shows the configuration parameters.

 How to choose an expression.

The expression is specified in this field. Must return a Boolean value. For example, the C # expression:

Customers.ID == 53447

If the expression returns a non-boolean value, the reporting tool cannot render an expression of this type.