Question

I have a user id from a synced contact, I now try to retrieve the raw twitter accounts that the sync adapter from the official twitter client creates. How would I specify the MIME Type for needed to filter for the Twitter Account?

The content of the MIME Type Column is:

Column Name is: mimetype Content is: vnd.android.cursor.item/vnd.twitter.profile

Was it helpful?

Solution

My bad. Another Error made the result I wanted to get invisible to me.

The following code gives you the synced twitter contact:

Cursor rawTwitterContact = getContentResolver().query(Data.CONTENT_URI, null, Data.CONTACT_ID + "=? AND " + Data.MIMETYPE + "='vnd.android.cursor.item/vnd.twitter.profile'", new String[] { String.valueOf(userId) }, null);
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top