0

my app crashed when i try to scroll down in ListView I've tried to trace the error i couldn't find it , the activity works fine but when i try to scroll down the app getting crashed , could you please guys tell me where is the error or what i mess in my code ?

i had removed the scroll down effect and removed also

lv.setOnScrollListener(new OnScrollListener()

but still same problem

listview xml

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools"
    android:orientation="vertical" 
    android:layout_width="fill_parent"
    android:layout_height="fill_parent"
    android:background="@drawable/background_scroller"
    >

    <ListView
        android:id="@+id/ringtoneListview"
        android:layout_width="fill_parent"
        android:layout_height="fill_parent" 
        android:background="@drawable/scrollback"
        android:divider="#93c7e8"
        android:dividerHeight="1dp" />

</LinearLayout>
4

1 回答 1

2

在这里,您将对象设置为 Long

convertView.setTag(r.getLong("toneid")) 

然后你想让这个相同的对象成为一个视图。ViewHolder(类型视图)

holder = (ViewHolder) convertView.getTag();
于 2013-04-25T10:32:54.920 回答