简体   繁体   中英

App is not showing in the share menu of shared options in shared extension in iOS8

I'm developing share extension for my app. Every thing is fine, but i'm facing one main problem, my app is not in the share menu while sharing from photos app.

Below is the plist of my shared extension.在此处输入图片说明

It's not showing in the list, below is the screenshot:

在此处输入图片说明

But when i go to more option, set the switch of my extension off and on, now it is showing in the list, But i need to do it every time, below are the screenshots:

在此处输入图片说明 在此处输入图片说明

Every time i ran the extension from X-Code, It's not showing the share menu, i need to go to more option, set the switch off and on again, then only it is showing. Can it show every time in the share menu? Is there anything i'm missing in the plist or extra configuration required?

I need your valuable suggestions. Thanks in advance.

Update:

I have checked it in iOS9. It's working fine without any issues.

For anyone having the same problem and not finding a solution, worth trying also to check "Deployment Target" of the extension.

It can be different that the main app and is setup by default when the extension is created.

In my case it was higher than what I had on my device.

This is a bug in iOS. There is no workaround in the current version. File a bug report with Apple and hope that they fix it soon.

我在 iOS 14 Beta 上遇到了这个问题,通过重启设备解决了。

Step by step flow for creating Share Extension

在此处输入图片说明

在此处输入图片说明

在此处输入图片说明

Then just Run the application

在此处输入图片说明

Check Out Plist count to be 1 (1 = allows attachment 1) for images

在此处输入图片说明

Plist

<key>NSExtension</key>
    <dict>
        <key>NSExtensionAttributes</key>
        <dict>
            <key>NSExtensionActivationRule</key>
            <dict>
                <key>NSExtensionActivationSupportsImageWithMaxCount</key>
                <integer>1</integer>
            </dict>
        </dict>
        <key>NSExtensionMainStoryboard</key>
        <string>MainInterface</string>
        <key>NSExtensionPointIdentifier</key>
        <string>com.apple.ui-services</string>
    </dict>

Useful inks

https://developer.apple.com/library/ios/documentation/General/Conceptual/ExtensibilityPG/ShareSheet.html

http://www.appcoda.com/ios8-share-extension-swift/

http://www.appcoda.com/tag/app-extension/

Sharing data from Extension to Main App information link & How to create Today's extension?

How to create widgets showing on home screen in iOS 10

I faced the same issue. I found, that in the Build Settings (of extension target) field Wrapper Extension was empty, while it should be assigned as "appex". Assigning "appex" to Wrapper Extension solved my problem.

扩展构建设置

I had encountered with the same problem and fixed it by changing deployment target version for the extension. In my case ios version of the device that was tested was lower than my target ios version for the extension

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM