tags:

views:

100

answers:

1

Keep getting "The constructor SimpleCursorAdapter(MyProgram, int, Cursor, int) is undefined" and am not sure why. Here is my code.

  Cursor c = mDbHelper.getAllTypes();
   startManagingCursor(c);
  SimpleCursorAdapter notes = new SimpleCursorAdapter(this, R.layout.list_item1, c, R.id.text1);
      setListAdapter(notes);

Any ideas?

+1  A: 

Looking at the API docs for SimpleCursorAdapter shows the following signature:

SimpleCursorAdapter(Context ctx, int layout, Cursor c, String[] from, int[] to)

So you need to modify your call accordingly.

JRL