I am using Kal calendar from http://github.com/klazuka/Kal. I want to use this calendar on my app, so I added the “Kal” folder to my project, and added the following code:
KalViewController *calendar = [[[KalViewController alloc] init] autorelease];
[self.navigationController pushViewController:calendar animated:YES];
This is my code:
#import "kalViewController.h"
- (void)viewDidLoad {
KalViewController *calendar = [[[KalViewController alloc] init] autorelease];
[self.navigationController pushViewController:calendar animated:YES];
}
Nothing happens. What did I do wrong?
Make sure navigationController is not nil and it is being initialized as the root view controller of your UINavigationController? If not, you can’t use pushViewController until you do that!
Try