Hi,
Trying to pass the data of an ArrayList, but the error appears in the methods
Your class ListAdapter needs to extend ArrayAdapter<Item>
.
Example:
public class ListAdapter extends ArrayAdapter<Item> {
public ListAdapter(Context context, int textViewResourceId) {
super(context, textViewResourceId);
}
public ListAdapter(Context context, int resource, List<Item> items) {
super(context, resource, items);
}
@Override
public View getView(int position, View convertView, ViewGroup parent) {
View v = convertView;
if (v == null) {
LayoutInflater vi;
vi = LayoutInflater.from(getContext());
v = vi.inflate(R.layout.itemlistrow, null);
}
return v;
}
}
Take a peek if this helps: ArrayAdapter