We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

load complex data from Sqlite

I have a list with incremental load.
For every given piece I have to read the detail
Is that the best approach?

5 Replies

DB Dinesh Babu Yadav Syncfusion Team August 30, 2017 01:35 PM UTC

Hi Laura, 
 
Thank you for using Syncfusion Products. 
 
Query 
Response 
Load data into SfListView from SQLite 
We have included in our KB documentation about “Loading the data from SQLite online/offline database in SfListView” similar to the reported query and please find the following link for more information’s.  
  
Support for incremental loading in SfListView 
We have prepared the KB documentation regarding the support for load more items when end of SfListView is reached and please refer the following KB link for more information. 
 
For every given piece I have to read the detail 
We could not able to understand the reported query. So, could you please share some additional details and exact requirement that you need to implement at your end using SfListView which would help us to analyze the requirement better and update you an appropriate solution. 
 
Please let us know if you require further assistance. 
 
Regards, 
Dinesh Babu Yadav 
 



LR Laura Ruggeri August 30, 2017 01:48 PM UTC

I had read this documentation.

I have a list of products that I read correctly from my database.

For each product I have to go to read data with complex queries and that can not be run along with the first one.

On native android in the getview (adapter list) i read these data and only if the scrool is not busy.



DB Dinesh Babu Yadav Syncfusion Team September 1, 2017 01:48 AM UTC

Hi Laura, 
 
Sorry for the inconvenience. 
 
Could you please confirm that your exact requirement is to whether you need to load the data by using complex queries when an item is being added to the visual layout like similar to ItemAppearing event in Xamarin Forms ListView. If yes, we have considered to provide support for ItemAppearing and ItemDisappearing event in SfListView by which you can achieve your requirement. We have added it into our feature request list, and the feature will be available in our upcoming 2017 Volume 4 main release. We will update you once the feature has been implemented 
 
Please let us know if you require further assistance. 
 
Regards, 
Dinesh Babu Yadav 



LR Laura Ruggeri September 1, 2017 07:12 AM UTC

Yes.

In addition to the ItemAppering and ItemDisappering, it would be helpful to have scroll status.

At the moment I resolved this way even if it is not optimal.

 private async void ScrollRows_Changed(object sender, ScrollChangedEventArgs e)
        {
            IsBusyScroll = true;
            var lastIndex = scrollRows.LastBodyVisibleLineIndex;
       
            await Task.Delay(600);
            if (lastIndex == scrollRows.LastBodyVisibleLineIndex)
            {
                IsBusyScroll = false;
                var rows = scrollRows.GetVisibleLines();
                try
                {
                    for (int i = 0; i < rows.Count; i++)
                    {
                        var row = rows[i];
                        ARTICOLO_BIND_LISTE bind = ViewModel.MagartItems[row.LineIndex];
                        if (bind.SET_ALL_DATO == false)
                        {
                            System.Diagnostics.Debug.WriteLine("APPERING SCROLL " + bind.IndexDisplay + "->" + bind.Descrizione);
                            ViewModel.LoadItemComplete(row.LineIndex);
                        }
                    }
                }
                catch { }
            }


        }



DB Dinesh Babu Yadav Syncfusion Team September 4, 2017 04:48 AM UTC

Hi Laura,  
  
Thanks for the update. 
  
Currently, we do not have support for “Detecting the different ScrollStates for ScrollView in SfListView” and we have already considered this as feature request. We have added it into our feature request list, and the feature will be available in our upcoming 2017 Volume 4 main release. We will update you once the feature has been implemented and included in release. 
  
Regards, 
Dinesh Babu Yadav 


Loader.
Live Chat Icon For mobile
Up arrow icon