CNContact.DeleteValue
---------------------

Deletes a value of a contact.

| Component | Version | macOS | Windows | Linux | Server | iOS SDK |
|---|---|---|---|---|---|---|
| [Contacts](component_Contacts.md) | [10.1](newinversion101.md) | ✅ Yes | ❌ No | ❌ No | ❌ No | ✅ Yes |

MBS( "CNContact.DeleteValue"; ContactIdentifier; Selector { ; Identifier } ) 

**MBS**( **"CNContact.DeleteValue";** /\* Deletes a value of a contact. \*/  
**$ContactIdentifier**; /\* The contact identifier.e.g. "46B1E34D-58F9-4B6B-A80D-0F71ABB87A0E" \*/   
**$Selector**; /\* Which value to set.e.g. "givenName" \*/   
**$Identifier**) /\* Optional; Identifier or label to delete only one entry in a list.  
Pass empty text to delete all. \*/ 

### Parameters

| Parameter | Description | Example | Flags |
|---|---|---|---|
| ContactIdentifier | The contact identifier. | "46B1E34D-58F9-4B6B-A80D-0F71ABB87A0E" |  |
| Selector | Which value to set. | "givenName" |  |
| Identifier | Identifier or label to delete only one entry in a list.   Pass empty text to delete all. |  | Optional |

### Result

Returns OK or error.

### Description

Deletes a value of a contact.  
Selector can be birthday, contactRelations, dates, departmentName, emailAddresses, familyName, givenName, imageData, imageDataAvailable, instantMessageAddresses, jobTitle, middleName, namePrefix, nameSuffix, nickname, nonGregorianBirthday, organizationName, phoneNumbers, phoneticFamilyName, phoneticGivenName, phoneticMiddleName, phoneticOrganizationName, postalAddresses, previousFamilyName, socialProfiles, thumbnailImageData, note, type, ImageData and thumbnailImageData or urlAddresses.  
  
PhoneNumbers, emailAddresses, postalAddresses, urlAddresses, contactRelations, socialProfiles, instantMessageAddresses and dates can specify a label/identifier to delete only one entry.  
### Examples

Delete home address:

 MBS ( "CNContact.DeleteValue"; $contactID ; "postalAddresses"; "home")  
Delete all emails:

 MBS ( "CNContact.DeleteValue"; $contactID ; "emailAddresses"; "")  
Delete job title:

 MBS ( "CNContact.DeleteValue"; $contactID ; "jobTitle")  
### See also

- [CNContact.SetValue](CNContactSetValue.md)

### Release notes

- **Version 10.1**
    - Added [CNContact.DeleteValue](https://www.mbsplugins.eu/CNContactDeleteValue.shtml) function.

### Blog Entries

- [New in the MBS FileMaker Plugin 10.1](https://www.mbsplugins.de/archive/2020-03-17/New_in_the_MBS_FileMaker_Plugi/monkeybreadsoftware_blog_filemaker)
- [Neues MBS FileMaker Plugin 10.1 - Über 6100 Funktionen in einem Plugin](https://www.mbsplugins.de/archive/2020-03-10/Neues_MBS_FileMaker_Plugin_101/monkeybreadsoftware_blog_filemaker)
- [MBS FileMaker Plugin 10.1 - More than 6100 Functions In One Plugin](https://www.mbsplugins.de/archive/2020-03-10/MBS_FileMaker_Plugin_101_-_Mor/monkeybreadsoftware_blog_filemaker)
- [MBS FileMaker Plugin, version 10.1pr6](https://www.mbsplugins.de/archive/2020-03-02/MBS_FileMaker_Plugin_version_1/monkeybreadsoftware_blog_filemaker)

This function checks for a license.

Created 2nd March 2020 , last changed 2nd March 2020

  
[CNContact.AddURLAddress](CNContactAddURLAddress.md) - [CNContact.EditInAddressbook](CNContactEditInAddressbook.md)

[HTML Version](CNContactDeleteValue.shtml)