4

Im using the endless adapter http://github.com/commonsguy/cwac-endless however whenever i return false (because i dont have anymore data to append) , as stated here http://github.com/commonsguy/cwac-endless/blob/master/README.markdown in appendinbackground, my activity crashes and in Logcat i get a message saying indexoutofbounds etc.

How do I make it so that I can stop loading extra data?

ProgramFOX
  • 6,131
  • 11
  • 45
  • 51
Faisal Abid
  • 8,900
  • 14
  • 59
  • 91

1 Answers1

3

As stated on the page you linked to:

If you have questions regarding the use of this code, please join and ask them on the cw-android Google Group. Be sure to indicate which CWAC module you have questions about.

We will need your stack trace as well, showing the exception.

CommonsWare
  • 986,068
  • 189
  • 2,389
  • 2,491
  • 3
    @VeryVito: You will notice this answer is nearly three years old. If you read [the component's README](http://github.com/commonsguy/cwac-endless), you will see that support is now through StackOverflow. Please follow the instructions in that README. – CommonsWare Oct 08 '12 at 18:00
  • I'm using endless adapter with gridview. Example shows progress image at bottom left, but I want to show it at bottom center. But even after I write android:layout_centerHorizontal="true" (of course my grid view and image are inside relativeLayout) after I run project it shows at bottom left. where shall I make changes? – Nayanesh Gupte Apr 29 '13 at 07:07
  • @NayAneshGupte: The only way to get what you want would be for you to have an odd number of columns, then always load in a number of elements that would cause the pending `View` to wind up in the center column. `EndlessAdapter` itself does not control positioning of elements within the `AdapterView` -- that is up to the `AdapterView` itself. – CommonsWare Apr 29 '13 at 11:15