Android Question Hide/Show a view when onScroll from a ListView is called

LucaMs

Expert
Licensed User
Uhm...

ListView has not an event on scrolling.

You could use CustomListView and set the height of the label "HideOnScrollExample" based on the position you get in ScrollChanged event of the scrollview.
 

LucaMs

Expert
Licensed User
You should add this routine to CustomListView:
B4X:
Private Sub sv_ScrollChanged(Position As Int)
    If SubExists(CallBack, EventName & "_ScrollChanged") Then
        CallSubDelayed2(CallBack, EventName & "_ScrollChanged", Position)
    End If
End Sub
so you can handle the ScrollChanged event in your Activity.
 

LucaMs

Expert
Licensed User
I don't know.

However:

1) I don't like that way of disappearing of the label :)
2) I think that to get the same effect, you should put the label in a second scrollview and synchronize the two scrolling.
 
Top