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

Similar Threads
thread Thread Starter Forum Replies Last Post
Can't open application nocakeforyou Mac Applications and Mac App Store 4 Jun 18, 2013 04:10 PM
is an application downloaded from the internet. Are you sure you want to open it hajime Mac Basics and Help 4 May 25, 2013 02:17 AM
cant open the application ProfilerPlus 2.3 macimux OS X 4 Mar 27, 2013 02:47 PM
New windows open behind current application miamirulz29 OS X 10.8 Mountain Lion 2 Dec 21, 2012 02:09 PM
MacBook Battery going with Application open kingdummkopf Mac Applications and Mac App Store 1 Jul 1, 2012 04:50 PM

Forum Jump

All times are GMT -5. The time now is 09:26 PM.

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

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