title: Share Extension not appearing in the list of apps on capable of Sharing Photo on iPhone
body: <p>I am trying to create a share app extension and followed the tutorial from this source:</p>
  
  <pre><code>http://www.technetexperts.com/mobile/share-extension-in-ios-application-overview-with-example/
  </code></pre>
  
  <p>I am using XCode 8.0 (8A218a) On simulator it works as expected. On my iPhone 5s with iOS 9.3.3.</p>
  
  <p>I install the container application first and then run Extension by choosing Photos app when XCode asks "Choose an app to run".</p>
  
  <p>Now when I open a photo while extension is running, the following error appears:</p>
  
  <pre><code>MobileSlideShow[3500:589624] *** error reading settings archive file: &lt;ISRootSettings:
  /var/mobile/Documents/com.apple.mobileslideshow.settings/ISRootSettings_10.plist&gt; 
  </code></pre>
  
  <p>Now when I tap the Share button, my container app doesn't appear in the list of Apps capable of Sharing picture.</p>
  
  <p><strong>EDIT:</strong>
  I am sharing some code:</p>
  
  <p><strong>ShareViewController.m</strong></p>
  
  <pre><code>@implementation ShareViewController
  - (BOOL)isContentValid {
      // Do validation of contentText and/or NSExtensionContext attachments here
      return YES;
  }
  
  - (void)didSelectPost {
  
      for (NSItemProvider* itemProvider in ((NSExtensionItem*)self.extensionContext.inputItems[0]).attachments ) {
  
          if([itemProvider hasItemConformingToTypeIdentifier:@"public.jpeg"]) {
              NSLog(@"itemprovider = %@", itemProvider);
  
              [itemProvider loadItemForTypeIdentifier:@"public.jpeg" options:nil completionHandler: ^(id&lt;NSSecureCoding&gt; item, NSError *error) {
  
                  NSData *imgData;
                  if([(NSObject*)item isKindOfClass:[NSURL class]]) {
                      imgData = [NSData dataWithContentsOfURL:(NSURL*)item];
                  }
                  if([(NSObject*)item isKindOfClass:[UIImage class]]) {
                      imgData = UIImagePNGRepresentation((UIImage*)item);
                  }
  
                  NSDictionary *dict = @{
                                         @"imgData" : imgData,
                                         @"name" : self.contentText
                                         };
                  NSUserDefaults *defaults = [[NSUserDefaults alloc] initWithSuiteName:@"group.iosApp.testSharing"];
                  [defaults setObject:dict forKey:@"img"];
                  [defaults synchronize];
              }];
          }
      }
  }
  
  @end
  </code></pre>
  
  <p><strong>ViewController.m</strong></p>
  
  <pre><code>@implementation ViewController
  
  - (void)viewWillAppear:(BOOL)animated {
  
      [super viewWillAppear:animated];
      NSUserDefaults *defaults = [[NSUserDefaults alloc] initWithSuiteName:@"group.iosApp.testSharing"];
      NSDictionary *dict = [defaults valueForKey:@"img"];
  
      if (dict) {
  
           NSData *imgData = [dict valueForKey:@"imgData"];
           UIImage *image = [UIImage imageWithData:imgData];
           [_shareImageView setImage:image];
           _shareImageNameLabel.text = [dict valueForKey:@"name"];
           [defaults removeObjectForKey:@"img"];
       }
  
   }
  
  @end
  </code></pre>