HI All,
I am trying to delete Contact field value in SDK early 5. I am using
update method of ContentResolver for update value like that

ContentResolver resolver =
getApplicationContext().getContentResolver();
ContentValues cv = new ContentValues();
cv.put(Contacts.People.NAME,"NAME");
int count = resolver.update(Contacts.People.CONTENT_URI, cv, "_ID =
'1'", null);

and everything works fine (count = 1) but if I`am trying to delete
field:

ContentResolver resolver =
getApplicationContext().getContentResolver();
ContentValues cv = new ContentValues();
cv.putNull(Contacts.People.NAME);
int count = resolver.update(Contacts.People.CONTENT_URI, cv, "_ID =
'1'", null);

nothing happens but count = 1 again . Also I`m replace
Contacts.People.CONTENT_URI to
Uri peopleUri =
ContentUris.withAppendedId(Contacts.People.CONTENT_URI, 1) but nothing
changed
Any ideas?

-- 
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

Reply via email to