0

Hey so I need help with this. I have to launch my application from email without the application being in the background process. Currently, the application has to be in the process for me to open the email attachment. Is there any UIApplicationDelegate that I can use in my AppDelegate so I don't need the application in the background. Right now, I have to tell my users to first open the application and then open the email attachment and this is proving quite difficult for some users.

1 Answers1

1

URL schemes is what you want.
http://mobile.tutsplus.com/tutorials/iphone/ios-sdk-working-with-url-schemes/

unexpectedvalue
  • 6,079
  • 3
  • 38
  • 62
  • that does't really help me since I am using the "- (BOOL)application:(UIApplication *)application handleOpenURL:(NSURL *)url " already to open my app from the email. But my app would only show the first proper page if there is that app process in the background when the email is opened. If that is not the case, then it shows just the same page that appears when u just open the app without clicking on the attachment. The attachment has to be opened for the app to do something useful. I just don't want to have to have the app process running in the background when the attachment is opened. – ProgrammerForNow Apr 18 '12 at 15:23
  • Please somebody help me out. This issue has bothered me for about a month and I have to do it fast. – ProgrammerForNow Apr 18 '12 at 15:43
  • When the app starts up cold, "- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions" gets called in place of handleOpenURL. This should give you the URL. – unexpectedvalue Apr 18 '12 at 17:25
  • But in my case when I click on the attachment it goes to handleOpenURL not didFInishLaunchingWithOptions. – ProgrammerForNow Apr 18 '12 at 18:28
  • Also, as a clue, I get this Thread 1: Program received signal: "SIGKILL" in the simulator when it stops in main at "int retVal = UIApplicationMain(argc, argv, nil, @"AppDelegate");". When I hit continue it works normally. But on a real device nothing the app would just show a spinning circle and then display the startup page without no attachment. – ProgrammerForNow Apr 18 '12 at 20:56