T taylorw Active Member Licensed User Jun 27, 2017 #1 Hi all,how to i get the customlistview scroll position? I already read this post. https://www.b4x.com/android/forum/t...ds-more-when-scroll-tot-bottom.35761/#content Code: Private Sub sv_ScrollChanged(Position As Int) If Position + sv.Height >= sv.Panel.Height Then If DateTime.Now > lastAddItemsTime + 200 Then lastAddItemsTime = DateTime.Now CallSub(CallBack, EventName & "_AddItems") End If End If End Sub But in this code i can't get customlistview scroll position.
Hi all,how to i get the customlistview scroll position? I already read this post. https://www.b4x.com/android/forum/t...ds-more-when-scroll-tot-bottom.35761/#content Code: Private Sub sv_ScrollChanged(Position As Int) If Position + sv.Height >= sv.Panel.Height Then If DateTime.Now > lastAddItemsTime + 200 Then lastAddItemsTime = DateTime.Now CallSub(CallBack, EventName & "_AddItems") End If End If End Sub But in this code i can't get customlistview scroll position.
Erel B4X founder Staff member Licensed User Longtime User Jun 27, 2017 #2 You need to implement it in the CustomListView class. Upvote 0
T taylorw Active Member Licensed User Jun 27, 2017 #3 Sorry Erel, i don't understand how to implement to customlistview class? Upvote 0
Erel B4X founder Staff member Licensed User Longtime User Jun 27, 2017 #4 Are you using the library? You should instead use the source code: CustomListView - A flexible list based on ScrollView Upvote 0
Are you using the library? You should instead use the source code: CustomListView - A flexible list based on ScrollView
T taylorw Active Member Licensed User Jun 27, 2017 #5 Is that true like this? Attachments upload_2017-6-27_17-3-33.png 117.1 KB · Views: 549 upload_2017-6-27_17-7-58.png 21.4 KB · Views: 538 Upvote 0
Erel B4X founder Staff member Licensed User Longtime User Jun 27, 2017 #6 This is CustomListView class. Upvote 0
T taylorw Active Member Licensed User Jun 27, 2017 #7 Ya Erel,i have using the library. And i already add this code in the class. But when i click run, then have this error. Upvote 0
Ya Erel,i have using the library. And i already add this code in the class. But when i click run, then have this error.
Erel B4X founder Staff member Licensed User Longtime User Jun 27, 2017 #8 You shouldn't use the library if you are using the source code. Upvote 0
mangojack Expert Licensed User Longtime User Jun 27, 2017 #9 Firstly .. Uncheck reference to CustomListView Library , you have included the class module instead (.bas) Next , in the CustomListView Class Globals edit sv AS ScrollView as Public Then in any module you can call .. Log(ListView_Order.sv.ScrollPosition) The error you are getting refers to unmatched sub signature ... Check that the parameters of Sub Create_OrderList matches those you are sending. Personally i would have populated an map and passed that instead for easier reading. Last edited: Jun 27, 2017 Upvote 0
Firstly .. Uncheck reference to CustomListView Library , you have included the class module instead (.bas) Next , in the CustomListView Class Globals edit sv AS ScrollView as Public Then in any module you can call .. Log(ListView_Order.sv.ScrollPosition) The error you are getting refers to unmatched sub signature ... Check that the parameters of Sub Create_OrderList matches those you are sending. Personally i would have populated an map and passed that instead for easier reading.
T taylorw Active Member Licensed User Jun 27, 2017 #10 Oh thanks, and sorry for my mistake. Thanks all. Upvote 0