Listview loaded event? RRS feed

  • Question

  • I am building a listview with data from an xhr request and i need to do something right after it completes loading. If i use a datasource i find i can't use a .then condition etc after it does an itemfromindex etc,similar to custom data sources example.I really need an event that indicates loading completion,and i also need a way to get the first item or top item but the docs don't seem useful.

    Thursday, March 8, 2012 8:23 PM


  • Hi V,

    Check out the documentation:


    loadingstatechanged - Occurs when the ListView switches between a loading and a ready state.

    indexOfFirstVisible - Gets or sets the first visible item.
    indexOfLastVisible - Gets the index of the last visible item in the ListView.

    or itemDataSource - Gets or sets the data source that provides the ListView with items. and you can get the first item in the list if you want that.

    Jeff Sanders (MSFT)

    Thursday, March 8, 2012 8:32 PM