开发者

The constructor SimpleCursorAdapter(MyProgram, int, Cursor, int) is undefined

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 SimpleCursorA开发者_Go百科dapter(this, R.layout.list_item1, c, R.id.text1);
      setListAdapter(notes);

Any ideas?


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.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜