I want to display the arrayList items in ListView which is having 2 different textViews. I am using ListViewCustomAdapter and getView(),getItem()... methods are there.
You have wrong implementation in some of the adapter methods.
getItem() should return the object from your list at the position:
@Override
public Object getItem(int position) {
return myList.get(position);
}
Then, in getView
@Override
public View getView(int position, View convertView, ViewGroup parent) {
// Create view
// ...
String[] item = (String[])getItem(position); // Get the current object at 'position'
// Update your view here
TextView t1=(TextView)List.findViewById(R.id.txtViewTitle);
t1.setText(item[0]);
TextView t2=(TextView)List.findViewById(R.id.txtViewDescription);
t2.setText(item[1]);
}
If your want to display two different strings, I suggest you list should look like this
[new String[]{"a1", "a2"}, new String[]{"b1", "b2"}, ...]