Hi
We have required using MVVM (prism) design where user should be able to see result in sflistview and it should auto load when scroll reaches to last record.
Also user can search in searchBar and result should show accordingly with load more available there as well.
Actually I tried, however on fresh load both commands (Search Command , Load More Command) are firing at once, which is not ideally I wanted.
Regards
Pawan Shakya
|
Query |
Response | ||
|
We have required using MVVM (prism) design where user should be able to see result in sflistview.
Also user can search in searchBar and result should show accordingly with load more available there as well. |
You can achieve your requirement using Filter predicate in SfListView.DataSource.
Please refer to the following code snippets for more reference,
ViewModel
XAML: Bind the ViewModel datasource property to SfListView.DataSource.
Please refer to our documentations regarding the same from the following link,
KB link: https://www.syncfusion.com/kb/11478/how-to-filter-xamarin-forms-listview-sflistview-using-mvvm
| ||
|
And it should auto load when scroll reaches to last record. |
You can achieve your requirement by using SfListView.LoadMoreOption as Auto.
Please refer to the following documentation regarding the same,
| ||
|
Actually I tried, however on fresh load both commands (Search Command , Load More Command) are firing at once, which is not ideally I wanted. |
We would like to inform you that, when LoadMoreOption is Auto then the LoadMoreCommand will be called in the following scenarios,
When items are less than the view size
When reaching the end of the list |