2

I need to install my iPhone app as shortcut.
If a user long-touches an image in an email attachment, this option should appear along with “Print”, “Save to camera roll”, “Facebook”, “Twitter” etc.
Can anyone help me with this? Any help would be appreciated.

Puneet Sharma
  • 9,369
  • 1
  • 27
  • 33
Sangie
  • 49
  • 8
  • 2
    http://stackoverflow.com/questions/2774343/how-do-i-associate-file-types-with-an-iphone-application – Stavash Jul 30 '13 at 07:03

1 Answers1

0

If you want your app to open the file of type .png,.jpeg or .pg, you must list Document type Key in Info.plist of your file as shown below:

<key>CFBundleDocumentTypes</key>
    <array>
        <dict>
            <key>CFBundleTypeName</key>
            <string>files</string>
            <key>LSHandlerRank</key>
            <string>Owner</string>
            <key>LSItemContentTypes</key>
            <array>
                <string>.png</string>
                <string>.jpegf</string>
                <string>.jpg</string>
            </array>
        </dict>
    </array>

Refer:
http://developer.apple.com/library/ios/#documentation/FileManagement/Conceptual/DocumentInteraction_TopicsForIOS/Articles/RegisteringtheFileTypesYourAppSupports.html

Puneet Sharma
  • 9,369
  • 1
  • 27
  • 33