Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

xArtx

macrumors 6502a
Original poster
Mar 30, 2012
764
1
Hi Guys,
I'm trying to associate my App with an image file extension. I've tried .bmp, and .png with no luck.

I've found what looks like some good info on the net:
http://stackoverflow.com/questions/2774343/how-do-i-associate-file-types-with-an-iphone-application
http://mobiforge.com/developing/story/importing-exporting-documents-ios?dm_switcher=true

Brad should know his stuff.

What I've noticed is that images in email seem to have a different menu
if you hold your finger on the attachment.
If I follow Brad's instructions with a made up extension (.bmx), my App does show in the stock
email app, but there is no longer any preview of the image in the email app.

Cheers, Art.
 
Last edited:

xArtx

macrumors 6502a
Original poster
Mar 30, 2012
764
1
Just a follow up (although I haven't resolved the issue in the first post),

It occurs to me that if you're only dealing with importing one file at a time,
such as a file being sent to your app from the stock email app,
you can just check the existence of the Documents/Inbox directory at
startup, check it's contents, and if a file exists, deal with it, and then
move it, or delete it from Documents/Inbox.

That way you don't have to add anything to AppDelegate or check the
imported file's URL. Your App can know at startup if it was launched by
the email app just because a file exists in the Documents/Inbox.
 

ArtOfWarfare

macrumors G3
Nov 26, 2007
9,559
6,059
You could utilize the pasteboard... have the user tap and hold on the image, select "copy", and then when your app is launched take whatever image is on the system pasteboard...
 

xArtx

macrumors 6502a
Original poster
Mar 30, 2012
764
1
You could utilize the pasteboard... have the user tap and hold on the image, select "copy", and then when your app is launched take whatever image is on the system pasteboard...

Thanks for the reply, and it's a good one, but it won't work for me this time :(
The pasteboard won't pass data.
It will pass the UIImage, but once the image data is inside that container,
it can't seem to be accessed at byte level, which is why I'm interested in bitmaps.

Since this time I'm going for a charged one. I can't have a user go through
more gestures than they know there needs to be. It would be ok for me,
but not for charging someone.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.