Android : Android using custom view PullToRefreshSwipeListView

on Wednesday, August 13, 2014


I am trying to use both PullToRefresh and SwipeListView libraries in listview using PullToRefreshSwipeListView custom view class. I have implemented it like that:


First I have imported PullToRefresh library into my project then I have added a SwipeListView Jar File into PullToRefresh library projet by making a libs folder in it. Then I have added PullToRefreshSwipeListView class in the src folder(com.handmark.pulltorefresh.library) of PullToRefresh library project. Finally I am trying to implement this custom class PullToRefreshSwipeListView into my project's xml as:



<com.handmark.pulltorefresh.library.PullToRefreshSwipeListView
xmlns:swipe="http://schemas.android.com/apk/res-auto"
xmlns:ptr="http://schemas.android.com/apk/res-auto"
android:id="@+id/lv_Inbox"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:cacheColorHint="#00000000"
android:divider="#19000000"
android:dividerHeight="2dp"
android:fadingEdge="none"
android:fastScrollEnabled="false"
android:footerDividersEnabled="false"
android:headerDividersEnabled="false"
android:scrollbars="none"
android:smoothScrollbar="true"
ptr:ptrAnimationStyle="flip"
swipe:swipeActionLeft="reveal"
swipe:swipeCloseAllItemsWhenMoveList="true"
swipe:swipeMode="both"/>


But I am getting error in xml as:



  • error: No resource identifier found for attribute 'swipeActionLeft' in package

  • error: No resource identifier found for attribute 'swipeActionLeft' in package

  • error: No resource identifier found for attribute 'swipeMode' in package


It does not get any of the swipe attribute but If I remove swipe attributes. It is working fine for only PullToRefresh. I am following this link to implement it. Any Solution/Comments will be most appreciated.


0 comments:

Post a Comment