-3

i want to perform two tasks i.e; scrolling and loding of data after scrolling task is completed using JSON http://www.souqalkhaleejia.com/webapis/featuredproducts.php?count=&currency=INR&limit=2 above mentioned url is JSON url for example like the way products load in flipkart app.

AllProducts.xml

<LinearLayout 
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:orientation="vertical">

    <include
        android:id="@+id/featuredtoolbar"
        layout="@layout/toolbar" />

    <android.support.v4.widget.SwipeRefreshLayout
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:id="@+id/swiperecycler" >

        <android.support.v7.widget.RecyclerView
            android:id="@+id/allfeaturedview"
            android:layout_width="match_parent"
            android:layout_height="wrap_content" />
    </android.support.v4.widget.SwipeRefreshLayout>

</LinearLayout>
prominere
  • 79
  • 2
  • 10

1 Answers1

0

Welcome to stackoverflow! You are referring to 'Enless Scrolling'.

Perhaps the following answer can be helpfull: How to implement endless list with RecyclerView? But since you're new to this, I'd recommend to start off with a tutorial, like this one (ListView): https://stevenkideckel.wordpress.com/2014/04/19/infinite-scrolling-list-view/

Next time try to first look if there is already information available on the subject. A search quite similar to your answer like "Scrolling and load more data listview" will already provide you with some details to get started.

For your answer, the source of the new data, in your case JSON, is not very relevant so you can exclude this from your search.

Community
  • 1
  • 1
Mdlc
  • 7,128
  • 12
  • 55
  • 98