views:

52

answers:

3

Hi Guys,

I am developing app with finding audio frequency by using FFT. In my app, I am not able to call application delegate method in app delegate class as given in below, but I could able to call other custom methods in app delegate class. What mistake I have done? Please help me!

  • (void)applicationDidFinishLaunching:(UIApplication *)application
A: 

Check to make sure your application delegate inherits from NSObject and NOT NSApplication as NSApplication is a singleton. Otherwise your application object will be its own delegate.

roguepixel
@roguepixel ya sure, I am inherits from NSObject only
Sivanathan
+2  A: 

It looks like your project files have got a bit mixed up. To be honest, it's probably easier to start with a new application template as a base and then add your changes into it. If that is not possible, have a look at the following

In your {project_name}.plist file under the Resources folder you should see a setting

Main nib file base name

This will tell you which nib file is loaded at the start (normally MainWindow). Open this file and have a look for 'Files Owner' 'UIApplication'. Right click on this and there should be a link to the delegate. If it isn't there, then that's your problem

Liam
@Liam Thanks! ya that is the problem, I solved it.
Sivanathan
A: 

You should now be using application:didFinishLaunchingWithOptions:

falconcreek