I am using Xamarin forms.
I am working with custom Listview component, I this list view I add on Entry. This Entry control I want to disable on condition
It is listview so I can not give the x:Name
IsEnabled="status == 'Rejected'"
As of my knowledge, we can't handle conditions in XAML file,
XAML cannot contain code. All event handlers must be defined in a code file.
XAML cannot contain loops for repetitive processing. (However, ListView —can generate multiple children based on the objects in its ItemsSource collection.)
XAML can not contain conditional processing(However, a data-binding can reference a code-based binding converter that effectively allows some conditional processing.)
XAML generally cannot instantiate classes that do not define a parameterless constructor. (However, there is sometimes a way around this restriction.)
XAML generally cannot call methods. (Again, this restriction can sometimes be overcome.)
I think you have to use a IValueConverter, that converts from String to Boolean
I took on status flag set value to this flag then use this flag.
Xamarin Inc., as a wholly-owned Microsoft subsidiary acting as a separate legal entity, adheres to the Microsoft Privacy Statement: Privacy & cookies