楼主让这个问题郁闷了一晚上。。。。。在logcat里明明显示adapter的getview方法里的list大于一条数据 ,但posotion却一直是0.。。。。运行后也只显示list[0]里面的数据。。。。最后的最后原来错误出在布局文件上
我以前的是这样的;
<ScrollView
android:layout_width="fill_parent"
android:layout_height="wrap_content"
>
<!-- listview -->
<ListView android:id="@+id/listview1" android:layout_width="fill_parent"
android:layout_height="fill_parent" android:drawSelectorOnTop="false"
android:background="@drawable/home_index_btn_d"
android:fadingEdge="none"
android:cacheColorHint="#00000000"
android:scrollbars="vertical" />
</ScrollView>都是这个ScrollView惹的祸。。。去掉之后 就OK了 。。。。。。。。。。Android 自定义Adapter 但listview 只显示第一条数据,布布扣,bubuko.com
Android 自定义Adapter 但listview 只显示第一条数据
原文地址:http://blog.csdn.net/fangchao3652/article/details/25564737