編輯

共用方式為


CNErrorCode Enum

Definition

Enumerates kinds of error encountered while working with contacts.

[ObjCRuntime.Introduced(ObjCRuntime.PlatformName.iOS, 9, 0, ObjCRuntime.PlatformArchitecture.All, null)]
[ObjCRuntime.Introduced(ObjCRuntime.PlatformName.MacOSX, 10, 11, ObjCRuntime.PlatformArchitecture.All, null)]
public enum CNErrorCode
type CNErrorCode = 
Inheritance
CNErrorCode
Attributes

Fields

Name Value Description
CommunicationError 1

An error occurred at the transport level.

DataAccessError 2

An error occurred while trying to access the data.

AuthorizationDenied 100

The user has denied the app access to their contacts.

NoAccessibleWritableContainers 101
RecordDoesNotExist 200

The CNContact does not exist.

InsertedRecordAlreadyExists 201

The inserted record is a duplicate.

ContainmentCycle 202

Code containment cycle error.

ContainmentScope 203

Code containment scope error.

ParentRecordDoesNotExist 204

The CNContact does not exist.

RecordIdentifierInvalid 205
ValidationMultipleErrors 300

Multiple errors occurred relating to validation.

ValidationTypeMismatch 301

There was a type mismatch during validation.

ValidationConfigurationError 302

The validation attempt was misconfigured.

PredicateInvalid 400

The T:Contacts.CNPredicate is invalid.

PolicyViolation 500

A policy validation error.

ClientIdentifierInvalid 600
ClientIdentifierDoesNotExist 601
VCardMalformed 700
VCardSummarizationError 701

Applies to