title: Saving an image as Contact Picture, and displaying it while incoming call
body: <p><strong>Requirement:</strong> I am saving some contacts into the user's iPhone along with a picture (dimensions same as the device). I want this picture to be displayed ON FULLSCREEN whenever the contact calls on that device.</p>
  
  <p><em>Noticed Example:</em> <a href="https://itunes.apple.com/in/app/truecaller-number-search-spam/id448142450?mt=8" rel="noreferrer">Truecaller</a> iOS app shows as Red image when the caller is  <strong>Identified as Spam</strong></p>
  
  <p><strong>Code:</strong> This is code I have used to save the contacts data. I am using <code>Contacts.framework</code></p>
  
  <pre><code>CNMutableContact *newContact = [CNMutableContact new];
  
  newContact.imageData = UIImagePNGRepresentation([UIImage imageNamed:@"blue_bg.png"]);
  
  newContact.contactType = CNContactTypePerson;
  newContact.givenName = user.firstName;
  newContact.middleName = user.middleName;
  newContact.familyName = user.lastName;
  
  NSArray *numbers = [[NSArray alloc] initWithArray:@[[CNLabeledValue labeledValueWithLabel:@"Main" value:[CNPhoneNumber phoneNumberWithStringValue:user.mobileNumber.stringValue]]]];
  
  newContact.phoneNumbers = numbers;
  
  CNContactStore *store = [CNContactStore new];
  CNSaveRequest *saveReq = [CNSaveRequest new];
  
  [saveReq addContact:newContact toContainerWithIdentifier:nil];
  
  NSError *error = nil;
  [store executeSaveRequest:saveReq error:&amp;error];
  
  if (error) {
      NSLog(@"Contact Save ERROR: %@", error.localizedDescription);
  }
  </code></pre>
  
  <p><strong>Current Scenario:</strong> I am getting this image in the iOS <code>Contacts App</code> but its not displayed when that user calls on the iPhone. How does Truecaller do it? What am I missing here? </p>