ComponentOne Binding Expressions for WPF and Silverlight
Introduction to Binding Expressions / The C1Binding Class / Using C1Binding Expression Syntax
In This Topic
    Using C1Binding Expression Syntax
    In This Topic

    C1Binding objects use the C1CalcEngine class to parse and evaluate expressions. The syntax supported is similar to the one used in Microsoft Excel®.

    You can use all the usual logical operators (=, >, <,.<>, >=, <=), arithmetic (+, -, *, /, ^), and you can group expressions using parentheses. For example:

                    "1+2*3 < (1+2)*3" returns TRUE (7 < 9).

    Any public properties in the binding source object can be used in expressions as well. For example:

                    "Price * 8.5%" returns the value of the Price property times 0.085.

    Properties that return collections or dictionaries are also supported. For example, assuming the DataContext object has a Children property:

                    "Children(Children.Count-1).Name" returns the name of the last child.

    Finally, the C1CalcEngine supports a subset of the functions available in Excel. See C1Binding Expression Syntax Elements for a list of these functions.