I am working through John Horton\'s Android Programming for Beginners, and am currently attempting to create a note-taking app. Horton has just introduced ListVie
Try
public class NoteAdapter extends BaseAdapter {
Context mContext = null;
public NoteAdapter(Context context){
mContext = context;
}
@Override
public View getView(int whichItem, View view, ViewGroup viewGroup){
// check if view has been inflated already
if (view == null){
LayoutInflater inflater = (LayoutInflater) mContext.getSystemService(Context.LAYOUT_INFLATER_SERVICE); // ERROR HERE
view = inflater.inflate(R.layout.listitem, viewGroup, false);
}
return view;
}
}