Getting Started : Filtering Tutorial

This sample demonstrates the creation of filters at design time.

Interactive Features:

Filtering Tutorial screenshot

Filtering Tutorial screenshot

Filtering Tutorial screenshot

The following is an image of the sample.

Filtering Tutorial screenshot



List of Valid Filter Expressions



Expression

Syntax

Description

Multiplication, Division

*, /

Multiplies or Divides first argument by second argument.

Addition, Subtraction

+, -

Adds first argument with second argument or Subtracts second argument from the first one.

Or

| |

Returns 1 if either the first argument or the second argument returns true.

And

&&

Returns 1 if both parameters return true.

Less Than

<

Returns true if first parameter is less than the second one.

Greater Than

>

Returns true if first parameter is greater than the second one.

Less Than Or Equal

<=

Returns true if first parameter is less than or equal to the second one.

Greater Than Or Equal

>=

Returns true if first parameter is greater than or equal to the second one.

Equal

=

Returns true if both arguments have the same value.

Match

match

Returns 1 if there is any occurrence of the right-hand argument in the left-hand argument. For example, [CompanyName] match 'RTR' returns 0 for any record whose CompanyName field does not contain RTR anywhere in the string.

Like

like

Checks if the field starts exactly as specified in the the right-hand argument. For example, [CompanyName] like 'RTR' returns 1 for any record whose CompanyName field is exactly RTR. You can use an asterisk as a wildcard. [CompanyName] like 'RTR*' returns 1 for any record whose CompanyName field starts with RTR. [CompanyName] like '*RTR' returns 1 for any record whose CompanyName field ends with RTR.

In

in

Checks if the field value is any of the values listed in the right-hand operand. The collection of items used as the right-hand should be separated by commas and enclosed with brackets({}). For example, [code] in {1,10,21} returns 1 for any record whose code field contains 1, 10 or 21. [CompanyName] in {RTR,MAS} returns 1 for any record whose CompanyName field is RTR or MAS.

Between

between

Checks if a date-field value between the two values is listed in the right-hand operand. For example, [date] between {2/25/2004, 3/2/2004} returns 1 for any record whose date field is greater or equal to 2/25/2004 and less than 3/2/2004. To represent the current date, use the token TODAY. To represent DateTime.MinValue, leave the first argument empty. To represent DateTime.MaxValue, leave the second argument empty.