Register FAQ / Rules Forum Spy Search Today's Posts Mark Forums Read
Go Back   MacRumors Forums > Apple Systems and Services > Programming > iPhone/iPad Programming

Reply
 
Thread Tools Search this Thread Display Modes
Old Jan 30, 2013, 11:26 AM   #1
waterskier2007
macrumors 68000
 
waterskier2007's Avatar
 
Join Date: Jun 2007
Location: White Lake, MI
Send a message via AIM to waterskier2007
Help with registering application to open xmls

I am attempting to get my app to handle xmls for loading of data. I have successfully gotten the app to be registered, so for example, when I open an xml in an email I get my app as one of the "Open In..." options. Then when I go to my app, in the delegate I am implementing

Code:
-(BOOL)application: openURL: sourceApplication: annotation
{
     //just for debugging
     NSString *urlString = [url description];
}
However, all of the variables in that method are nil. It is getting called because I am setting some breakpoints, but url, sourceapplication, annotation are all nil.

Does anyone have any idea what I could be doing wrong?
__________________
2012 Mac Mini, 2.6 GHz, 16GB RAM, 1TB HDD
2.4Ghz 15" Macbook Pro
16 GB iPhone 5 : 32 GB iPhone 4S : 16 GB iPad 3
16 GB Nexus 7 (2012)

Last edited by waterskier2007; Feb 5, 2013 at 10:49 AM.
waterskier2007 is offline   0 Reply With Quote
Old Jan 30, 2013, 02:53 PM   #2
chown33
macrumors 603
 
Join Date: Aug 2009
If that's not your actual code, post your actual code.

If that is your actual code, you're missing the parameters.
chown33 is offline   0 Reply With Quote
Old Jan 31, 2013, 08:59 AM   #3
waterskier2007
Thread Starter
macrumors 68000
 
waterskier2007's Avatar
 
Join Date: Jun 2007
Location: White Lake, MI
Send a message via AIM to waterskier2007
Quote:
Originally Posted by chown33 View Post
If that's not your actual code, post your actual code.

If that is your actual code, you're missing the parameters.
I left out the parameters because I didn't feel like typing them, my apologies.

It ended up working after a while, with no change by me. Not sure what it was but it's possible it just took some time to fully register the app to accept the incoming file information...


Code:
-(BOOL)application:application openURL:url sourceApplication:sourceApplication annotation:annotation
{
     //just for debugging
     NSString *urlString = [url description];
}
__________________
2012 Mac Mini, 2.6 GHz, 16GB RAM, 1TB HDD
2.4Ghz 15" Macbook Pro
16 GB iPhone 5 : 32 GB iPhone 4S : 16 GB iPad 3
16 GB Nexus 7 (2012)
waterskier2007 is offline   0 Reply With Quote
Old Jan 31, 2013, 03:55 PM   #4
ianray
macrumors 6502
 
Join Date: Jun 2010
Location: @
Quote:
Originally Posted by waterskier2007 View Post
It ended up working after a while, with no change by me. Not sure what it was but it's possible it just took some time to fully register the app to accept the incoming file information...
Odd.

I experimented with adding VCard support so that my App could open saved locations from the Maps App. I could not get the Mail App to open my App for VCards. It did work with PDFs though (no reboots, no time -- it just worked).
__________________
My App Store Apps: Dashometer, Exinf, Score&Grade
ianray is offline   0 Reply With Quote

Reply
MacRumors Forums > Apple Systems and Services > Programming > iPhone/iPad Programming

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -5. The time now is 10:07 AM.

Mac Rumors | Mac | iPhone | iPhone Game Reviews | iPhone Apps

Mobile Version | Fixed | Fluid | Fluid HD
Copyright 2002-2013, MacRumors.com, LLC