Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

iOS 6 File Type Association Issues

I've run into a problem that appears to be restricted just to iOS 6 devices -- iOS 5 seems to handle this situation well.


I'm building an application that exports JSON-formatted files with a custom extension via email, and should also be able to open the file attachment from within mobile mail using the "Open with" dialog. Basically just a way to send your app's settings to other users of the app via email. These are small files as well -- less than 200KB.


The problem I've run into is that even though my application name appears in the list of available applications to open the attachment, iOS 6 devices fail to open my application. In the device logs, the following gets reported:


LaunchServices: Invalid LSOpenOperation request - No applications found to open document


I've been looking for anything online about this kind of issue, but haven't found any reference to that console output. I'm also positive that I've set up the Document Type and Exported UTI items correctly -- again this all works fine in iOS 5. I've included the values defined for the Document Type and UTI below:


Document Type

============

<key>CFBundleDocumentTypes</key>

<array>

<dict>

<key>CFBuldlerTypeRole</key>

<string>Editor</string>

<key>CFBundleTypeExtensions</key>

<array>

<string>exportedModel</string>

</array>

<key>CFBundleTypeIconFiles</key>

<array>

<string>icon</string>

</array>

<key>CFBundleTypeName</key>

<string>Exported Model</string>

<key>LSHandlerRank</key>

<string>Owner</string>

<key>LSItemContentTypes</key>

<array>

<string>com.company.applicationName.exportedModel</string>

</array>

</dict>

</array>



Exported UTI

==========

<key>UTExportedTypeDeclarations</key>

<array>

<dict>

<key>UTTypeConformsTo</key>

<array>

<string>public.text</string>

</array>

<key>UTTypeDescription</key>

<string>Exported Model</string>

<key>UTTypeIdentifier</key>

<string>com.company.applicationName.exportedModel</string>

<key>UTTypeTagSpecification</key>

<dict>

<key>public.filename-extension</key>

<string>exportedModel</string>

<key>public.mime-type</key>

<string>application/octet-stream</string>

</dict>

</dict>

</array>



Has anyone else seen this kind of behavior in iOS 6? Could there be a cache of file type associations that is messing the "Open with" operation up?

iOS 6

Posted on Nov 8, 2012 6:34 AM

Reply
3 replies

Nov 13, 2012 6:35 AM in response to gsilis

We received a solution from Apple developer support a few days ago, thought I'd post this here in hopes that it gets indexed for anyone who runs into this problem. I can't speak to this being a change from iOS 5 to iOS 6, even though it would appear that way.


The mime type set in the Exported UTI must match up with the mime type of the email attachment. Our plist file had the mime type set to application/octet-stream, but the email was being attached as an application/json mime type. If these don't match, it appears that your application will appear in the "Open with..." menu, but it won't launch your application when you try to open an email attachment.


We switched both to application/json and it fixed the problem.

Jul 13, 2013 5:13 AM in response to gsilis

Hi! You have given me some hope - I have a very similar problem and too have been tearing my hair out. My app has stopped launching in iOS6 from an email attachment containing XML data, but of a user defined type .ftl. My application was launched in iOS 4 without any problems and I get the same:


LaunchServices: Invalid LSOpenOperation request - No applications found to open document


Error .... My .info file is also absolutely fine. Mate, how do you establish the MIME type of your email attachment?


Regards,



Lee

iOS 6 File Type Association Issues

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple ID.