I am developing an app in Xamarin Android along with MvvmCross. MvvmCross helps to bind view properties in layout directly to ViewModels. For EditText, we can bind the text like
<EditText
android:layout_width="match_parent"
android:layout_height="wrap_content"
local:MvxBind="Text Property" />
I need to bind SearchView text using MvvmCross. I tried Text
like below but it doesn't work.
<SearchView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:queryHint="Customer name"
local:MvxBind="Text SearchString" />
How Is it possible to bind SearchView text using MvvmCross?
For SearchView
you need to use the Query
property:
<SearchView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:queryHint="Customer name"
local:MvxBind="Query SearchString" />
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With