AnsweredAssumed Answered

How delete contact from contact list ?

Question asked by jon on Jun 13, 2010
Latest reply on Jun 22, 2010 by jon

Hello,

I'm looking for a way to delete a contact. Here is my function, but I cannot delete the contact ...

 

public void deleteContact() {
 Workspace workspace = SparkManager.getWorkspace();


 String user = new UserManager().getNickname();
 String userGroup = this.isMemberOf(user);
 ContactList contactList = workspace.getContactList(); 
 List<ContactGroup> contactgroups = contactList.getContactGroups();
 
 for(ContactGroup group : contactgroups) {
 List<ContactItem> contactitems = group.getContactItems();
 for(ContactItem contact : contactitems) {
     
     // delete contact ??
 }
 }
 }

 

Can you help me please?

Thank you

Outcomes