Two different views with CursorAdapter

Put problem concerning Views, Layouts and other XML-Resources (like AndroidManifest) here.

Two different views with CursorAdapter

Postby chouman » Thu Jan 15, 2009 9:44 pm

I am not sure if you can do this, but essentially what I am trying to do is to use a CursorAdapter with a list that has two different views. To be more specific, I am trying to have a different view for an item in the list that's selected than the rest of the items in the list that's not selected. Is this possible?

If so how? some code snippet would help greatly
chouman
Developer
Developer
 
Posts: 27
Joined: Thu Jan 03, 2008 2:59 pm

Top

Postby MrSnowflake » Fri Jan 16, 2009 10:25 am

You should implement your own Adapter, which then return different views based on the type of data the list asks for.
User avatar
MrSnowflake
Moderator
Moderator
 
Posts: 1439
Joined: Sat Feb 16, 2008 3:11 pm
Location: Flanders, Belgium

Top

Return to View, Layout & Resource Problems

Who is online

Users browsing this forum: No registered users and 3 guests