tags:

views:

431

answers:

1

I am wanting to query the members of a given playlist. I have the correct playlist id, and want to use a managedQuery() to look at the playlist members in question.

What I have is this:

private String [] columns = { 
     MediaStore.Audio.Playlists.Members.PLAYLIST_ID,
     MediaStore.Audio.Playlists.Members.TITLE,
     };
Uri membersUri = MediaStore.Audio.Playlists.Members.getContentUri(volume, playlistId);
Cursor tCursor = managedQuery(membersUri, columns, null, null, null);

I don't know what the volume argument needs to be. I've tried this: MediaStore.Audio.Playlists.EXTERNAL_CONTENT_URI.toString() for the "volume" argument.

That gives me back a valid content URI that looks like:

content://media/external/audio/playlists/2/members

However, my cursor comes back null. I probably am way off base -- I know what I want to do is very simple.

+1  A: 
hexatron