Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7013857
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T22:26:44+00:00 2026-05-27T22:26:44+00:00

I am trying to create a new document UTI for my App so that

  • 0

I am trying to create a new document UTI for my App so that people can share points of interest with others. From what I can understand on SO, Tutorials, and from Apple’s documentation, you need to do the following:

  1. Create a Document Type in the .plist
  2. Create an Exported UTI that corresponds with it
  3. Use the method: -(BOOL)application:(UIApplication *)application
    didFinishLaunchingWithOptions:(NSDictionary *)launchOptions

From what I understand, as long as you did those right, you should be able to open the file through Mail without any problems. Unfortunately it isn’t working for my own custom UTIs. I DO see my App in the list of “Open with…” in Mail, but when I select it, my App doesn’t open at all. It just dosen’t do anything at all not only when the App isn’t open, but when the App is open. Mail stays up and nothing happens at all. I also checked the console using “Organizer” and there is absolutely nothing that happens.

Originally I thought my plist was wrong, so I tested opening a public UTI (I added the com.adobe.pdf document type) and my app launched just fine (though it promptly crashed because I don’t actually support PDFs ;)). But the point was that it launched without any problem.

The only thing I can think of that might be a problem is HOW I am creating the file. I am creating the file in an email by the use of this method (also in the App to export):

MFMailComposeViewController *picker = [[[MFMailComposeViewController alloc] init] autorelease];
[picker setSubject:[NSString stringWithFormat:@"My place: %@",POIName]];
[picker addAttachmentData:customPOIData mimeType:@"application/customPOI" fileName:[NSString stringWithFormat:@"%@.icp",POIName]];
[picker setMessageBody:@"Check out this great place I found!" isHTML:NO];
[picker setMailComposeDelegate:self];
[self presentModalViewController:picker animated:YES];

Is there anything wrong with that?

Also, here is my plist code:

CFBundleDocumentTypes:

<key>CFBundleDocumentTypes</key>
<array>
    <dict>
        <key>CFBundleTypeIconFiles</key>
        <array/>
        <key>CFBundleTypeName</key>
        <string>Custom POI</string>
        <key>CFBundleTypeRole</key>
        <string>Viewer</string>
        <key>LSHandlerRank</key>
        <string>Owner</string>
        <key>LSItemContentTypes</key>
        <array>
            <string>com.imadev.icp</string>
        </array>
    </dict>
</array>

UTExportedTypeDeclarations:

<key>UTExportedTypeDeclarations</key>
<array>
    <dict>
        <key>UTTypeConformsTo</key>
        <array>
            <string>public.data</string>
        </array>
        <key>UTTypeDescription</key>
        <string>Custom POI</string>
        <key>UTTypeIdentifier</key>
        <string>com.imadev.icp</string>
        <key>UTTypeTagSpecification</key>
        <dict>
            <key>public.filename-extension</key>
            <array>
                <string>icp</string>
            </array>
            <key>public.mime-type</key>
            <string>application/customPOI</string>
        </dict>
    </dict>
</array>

Thanks a lot for any help!!
-Mark

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T22:26:44+00:00Added an answer on May 27, 2026 at 10:26 pm

    I finally figured out what was wrong by pulling apart all the code.

    When I change “public.filename-extension” to a string and not an array of strings it works. Don’t ask me why… I think it’s strange we can’t use an array of file extensions. But apparently that was it.

    Any ideas as to why that happened?

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to create a new project in NetBeans PHP from existing sources. When
I'm trying to create a new environment in my LaTeX document where indentation in
I am trying to create the following XML document- FileStream fs = new FileStream(path,
I am trying to create a new node that is a child of an
I am trying to create a word document from a java application and am
I am trying to create a unit test that generates an empty test document
I'm trying to create new web page as like http://drag-2-share.appspot.com . I copied the
I'm trying to import a node from a base-document into a new document but
I am trying to create new Event objects to be persisted in the database
I'm trying to create a new Excel file using jxl, but am having a

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.