Titanium Community Questions & Answer Archive

We felt that 6+ years of knowledge should not die so this is the Titanium Community Questions & Answer Archive

appendRow and setData Problem

I am using the method setData to load more content in a table view. If there is more content to load I create a tableViewRow that when click calls the function to load more. Currently I am simply pushing the data to the array and then setting the data using the setData(array) method. The problem I am seeing is that when I do this in Android, the tableview scrolls all the way to the top and I do not want this behavior. I then attempted to use appendRow for every single row (which I know reduces performance as it is called so many times), but I found out that every time a row is appended the tableview also scrolls to the top. Is there a way to prevent this behavior so that when the next rows are loaded, they are simply appended to the previous rows?

This works on iPhone without the scrolling to the top. Any ideas?

— asked August 19th 2010 by Abraham Vivas
  • android
  • appendrow
  • setdata

1 Answer

The ownership of individual contributions to this community generated content is retained by the authors of their contributions.
All trademarks remain the property of the respective owner.