Bug? Customlistview, scrolltoitem problem

Discussion in 'Bugs & wishlist' started by kohle, Mar 23, 2018.

  1. kohle

    kohle Active Member Licensed User

    I have the customlistview 1.76 in serveral projects and no time to change this projects to xcust...

    scrolltoitem and jumptoitem dont work.

    For check, I downloaded the example from : https://www.b4x.com/android/forum/t...xible-list-based-on-scrollview.19567/#content

    and I made the changes to the code :

    Sub Activity_Create(FirstTime As Boolean)
    "Aaaa" & CRLF & "Bbbb""b")
    "Aaaa" & CRLF & "Bbbb" & CRLF & "Cccc""c")
    "Aaaa" & CRLF & "Bbbb" & CRLF & "Cccc" & CRLF & "Dddd" , "d")
    "Aaaa" & CRLF & "Bbbb" & CRLF & "Cccc" & CRLF & "Dddd" & CRLF & "Eeee""e")
    For i = 1 To 30
    $"Item #${i}"$, clv2.AsView.Width, 70dip), 70dip$"Item #${i}"$)
    End Sub

    It dont work. I have b4a 8

    Edit : I checked sample of xcustom... Dont work too.
    Edit : If I put a breakpoint it works. Without breakpoint no.
    Last edited: Mar 23, 2018
  2. Erel

    Erel Administrator Staff Member Licensed User

    This is not a bug. ScrollView layout is not immediately ready. Try it with Sleep(100) before you try to jump.
  3. kohle

    kohle Active Member Licensed User

    it works, small list, , but maybe its better to include a "retrieveend event"
  4. Erel

    Erel Administrator Staff Member Licensed User

    No event is raised for that. My guess that it will work with Sleep(0) as well.
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice