Something like this should work:
Cursor cur = managedQuery(People.CONTENT_URI, PROJECTION, null,
null);
SimpleCursorAdapter adapter = new SimpleCursorAdapter(
this,
android.R.layout.simple_spinner_item,
cur,
new String[] {People.NAME},
new int[] {android.R.id.text1});
adapter.setDropDownViewResource(
android.R.layout.simple_spinner_dropdown_item);
spinner.setAdapter(adapter);
--
Jack Ha
Open Source Development Center
・T・ ・ ・Mobile・ stick together
The views, opinions and statements in this email are those of
the author solely in their individual capacity, and do not
necessarily represent those of T-Mobile USA, Inc.
On Aug 25, 5:54 am, MMC2 <[email protected]> wrote:
> How do you populate a spinner from a cursor accessing an SQLite
> database?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~----------~----~----~----~------~----~------~--~---