Scrollview with paging in android
I think that there is not a fast solution to do this.
But what you can do is to take the gallery component and override the layout. The gallery component has paging :)
Another solution could be:
Horizontal Pager - https://github.com/ysamlan/horizontalpager
Real View Switcher http://marcreichelt.blogspot.com/2010/09/android-use-realviewswitcher-to-switch.html
Hope this helps...
user1083284
Updated on August 09, 2022Comments
-
user1083284 over 1 year
is there a simple/native way to implement paging/pagination on scrollviews? By simple, I mean with a short piece of code mainly using classes from Android SDK, like, when programming on iPhone, writing "pagingEnabled = YES".
When I was looking for the topic on the Internet, I saw people putting pieces of code about that matter, but these pieces of code were very large, and I can't help myself to believe Google did put a simple way to do it in their SDK. I also think that the code to implement it could be much easier than what I saw when looking for it. I'm currently working on it, but in the meantime, if anyone know a easier way to do it, I would be delighted to know about it.
Thanks for reading!
-
user1083284 over 12 yearsThanks a lot! The HorizontalPager is exactly what I needed, and it works perfectly. Awesome!
-
Marchy over 11 yearsGoogle released their own ViewPager library as part of the Android Compatibility Package (revision 3) which you can use for this. You should use that for any new development instead of HorizontalPager (as they also recommend from their own page).