9 messages in com.googlegroups.android-beginners[android-beginners] Re: displaying co...
FromSent OnAttachments
Sylvester Steele15 Jun 2008 10:37 
Megha Joshi18 Jun 2008 11:23 
Sylvester Steele18 Jun 2008 11:26 
Sylvester Steele19 Jun 2008 21:03 
Sylvester Steele20 Jun 2008 02:44 
Sylvester Steele20 Jun 2008 03:50 
Mark Murphy20 Jun 2008 04:41 
Mark Murphy20 Jun 2008 04:46 
Sylvester Steele20 Jun 2008 10:04 
Subject:[android-beginners] Re: displaying contacts in a list
From:Sylvester Steele (sylv@gmail.com)
Date:06/20/2008 03:50:35 AM
List:com.googlegroups.android-beginners

I have also tried:

activity.setContentView(R.layout.contacts); Cursor C = activity.getContentResolver().query(People.CONTENT_URI, null, null, null, null); activity.startManagingCursor(C);

String[] columns = new String[] {People.NAME}; int[] names = new int[] {R.id.contactsList};

SimpleCursorAdapter mAdapter = new SimpleCursorAdapter(activity, R.layout.contacts, C, columns, names); ListView contactsList= (ListView)activity.findViewById(R.id.contactsList); contactsList.setAdapter(mAdapter);

Here is gives me an exception saying: ListView is not a view that can be bounds by this simpleCursorAdapter.

Please help.

Thanks, Sylvester