Error occurred in appDelegate.m file while i run the sample signal aborted at
self.view.controller=root.view.controller
please help me i added code below
-(BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
/* bad signal occurred at this line */
self.window.rootViewController=self.viewController;
[self.window makeKeyAndVisible];
return YES;
}
thanks
The UIWindow rootViewController property doesn’t exist before iOS4. If you’re trying to run this code on an device with iOS 3 or older, it will crash.
In your AppDelegate, you can use addSubview instead.
//self.window.rootViewController = self.viewController; // Only iOS >= 4
[self.window addSubview:self.viewController.view];
[self.window makeKeyAndVisible];
return YES;
Hope this helps.