dreamer wrote:
[...]
> How can I make a custom list view, such that each item has for e.g a
> scroll text, image and a label.
>
> Ive checked it several times but to no success. Also how to do this
> thru layout XML only( without coding) if its possible.
The easiest way I found to do that is to produce an XML fragment
describing a single item, then use a SimpleCursorAdapter to replicate
and populate the fragment for each line:
SimpleCursorAdapter adapter =
new SimpleCursorAdapter(this, R.layout.list_item_layout,
_cursor, FromColumns, ToColumns);
adapter.setViewBinder(this);
This will require you to access your list data via a cursor, but that's
probably a good idea anyway.
I have found, though, that I couldn't make ImageView.setImageURI() work
properly, so none of my images in the list view are getting populated.
Don't know what's going on there.
--
David Given
[EMAIL PROTECTED]
--~--~---------~--~----~------------~-------~--~----~
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]
Announcing the new M5 SDK!
http://android-developers.blogspot.com/2008/02/android-sdk-m5-rc14-now-available.html
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~----------~----~----~----~------~----~------~--~---