Alex141 / CalcBinding

Advanced WPF Binding which supports expressions in Path property and other features

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

When should I use single quotes' and parentheses()?

CodingOctocat opened this issue Β· comments

I see the following usage in the documentation:

use one single quotes:   πŸ‘‡
<TextBox Text="{c:Binding '(A == 2) ? local:Class.A :4 + local:Class.B}"/>
use two single quotes:         πŸ‘‡                                                      πŸ‘‡
 <Button Background="{c:Binding '(A > B ? media:Brushes.LightBlue : media:Brushes.White)'}"/>

I find that sometimes one single quote is used, sometimes two single quotes are used, sometimes parentheses are needed, sometimes not, what does the correct syntax really look like?