BindingCondition BindingCondition Class

Definition

Class that represents a value comparison with the target of an arbitrary binding.

[Xamarin.Forms.Xaml.AcceptEmptyServiceProvider]
public sealed class BindingCondition : Xamarin.Forms.Condition, Xamarin.Forms.Xaml.IValueProvider
type BindingCondition = class
    inherit Condition
    interface IValueProvider
Inheritance
BindingConditionBindingCondition
Attributes
Implements

Remarks

The BindingCondition class can compare a value a binding on any class within the current scope. Developers who want to compare to a value to a bound property on the control that contains the conditions surrounding MultiTrigger may want to use a PropertyCondition in addition to any binding conditions in the trigger list.

The XML example below creates a binding condition within a surrounding MultiTrigger (omitted) that succeeds when the referenced name has a Text.Length property length that is equal to 0. (name must refer to an element, such as a TextCell, that has a Text property that, in turn, has a Length property.)


    <BindingCondition Binding="{Binding Source={x:Reference name},
                                    Path=Text.Length}"
                                    Value="0" />

Constructors

BindingCondition() BindingCondition()

Initializes a new BindingCondition instance.

Properties

Binding Binding

Gets or sets the binding against which the Value property will be compared.

Value Value

The binding value that satisfies the condition.

Explicit Interface Implementations

IValueProvider.ProvideValue(IServiceProvider) IValueProvider.ProvideValue(IServiceProvider)

Used by the XAML infrastructure.

Extension Methods

LoadFromXaml<TXaml>(TXaml, String) LoadFromXaml<TXaml>(TXaml, String)

Returns an initialized view by loading the specified xaml.

LoadFromXaml<TXaml>(TXaml, Type) LoadFromXaml<TXaml>(TXaml, Type)

Returns a TXaml with the properties that are defined in the application manifest for callingType.

Applies to

See Also