ios - Standard arguments in main file -


After

Is the standard argument in the main file. I think I have set incorrect standard arguments in the main file, and need to change them back. I think the problem is zero and zero in the UIApplicationMain arguments

Here is the code:

  #import & lt; UIKit / UIKit.h & gt; Integer main (int argc, char * argv []) {NSAutoreleasePool * pool = [[NSAutorelease Pool alloc] init]; Int retVal = UIApplicationMain (argc, argv, zero, zero); [Bridge release]; Return rate; }   

Error code:

  1420. 2011-09-02 Attached to action on 14: 33: 04.440 HypnoTime [1420] 207] *** assertion UIApplicationMain (), failure /SourceCache/UIKit_Sim/UIKit-1448.89/UIApplication.m:1359 2011-09-02 14: 33: 04.588 HypnoTime [1420: 207] *** not come the exception 'NSInternalInconsistencyException' because of his closing applications, because: 'UIApplication representative example is not load a class called Aepdileget unable to instantiate. '*** Call stack on first throw: (0 Core forwarding 0x00dc15a9 __exceptionPreprocess + 185 1 libobjc.A.dylib 0x00f15313 objc_exception_throw + 44 2 Corplacement 0x00d79ef8 + [NSE expansion lift: format: logic] + 136 3 Foundation 0x00816341 - [NSASERTHY Handler Handlefilier Infnkshna file: LineNumber: Description:] + 101 4 UIKit 0x00021bcd UIApplicationMain + 962 5 HypnoTime 0x000027cf main + 127 6 HypnoTime 0x00002745 start + 53 7 ??? 0x00000001 0x0 +1) to finish is called an example of 'NSException' current language After Throwing: Auto; Currently Objective-C (gdb)    

UIApplicationMain final argument the name of your UIApplicationDelegate of Subclass If you program to make your application it is necessary, any

  int retval = UIApplicationMain (argc, argv, zero, NSStringFromClass ([YourAppDelegate square]) without nib files).   

You #import "YourAppDelegate.h" needs to it to work that way, or you can simply hardcoded name like Voloda2 Have suggestions.

Use this way to profit if your change names your application representative class, you will get a compiler promptly warning, while if it is hardcoded, it will be built & Run without warning, but crash.

Comments

Popular posts from this blog

mysql - BLOB/TEXT column 'value' used in key specification without a key length -

c# - Using Vici cool Storage with monodroid -

python - referencing a variable in another function? -