【问题标题】:use PullToRefreshExpandableListView with custom fragment将 PullToRefreshExpandableListView 与自定义片段一起使用
【发布时间】:2013-10-16 14:42:52
【问题描述】:

所以我刚刚尝试在扩展 Fragment 的自定义片段中使用 PulltoRefreshExpandableListView,但是当我尝试设置适配器时,出现以下错误:

mPullRefreshExpandableListView.setAdapter(适配器);

setAdapter(android.widget.ListAdapter) 在 PullToRefreshAdapterViewBase 中无法应用 到 (sinfic.mobile.ipdms.adapters.GenericMultiColumnIconLineExpandableAdapter)

GenericMultiColumn....适配器扩展了 BaseExpandableAdapter。最好的解决方案是什么?

【问题讨论】:

    标签: listview android-fragments pull-to-refresh


    【解决方案1】:

    试试这个

    ExpandableListView actualListview = mPullRefreshExpandableListView.getRefreshableView();
    
    actualListView.setAdapter(adapter);
    

    【讨论】:

      猜你喜欢
      • 2014-06-02
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2013-03-10
      • 1970-01-01
      • 1970-01-01
      • 2017-09-30
      • 2017-07-04
      相关资源
      最近更新 更多