No declaration of property 'MyViewController' found in the interface.
Hi..
New in here.. I need some help, to be honest.. I just started out with the "Your First iPhone OS Application."
I get the error "no declaration of property 'MyViewController' found in the interface," in my "Hello_WorldAppDelegate.m" (here the error is in @synthesize)
My: Hello_WorldAppDelegate.h is as following:
#import <UIKit/UIKit.h>
@class MyViewController;
@interface Hello_WorldAppDelegate : NSObject <UIApplicationDelegate> {
UIWindow *window;
MyViewController *myViewController;
}
@property (nonatomic, retain) IBOutlet UIWindow *window;
@property (nonatomic, retain) MyViewController *myViewController;
@end
Which I think is where my 'interface' should be.
And my Hello_WorldAppDelegate.m is as following:
#import "MyViewController.h"
#import "Hello_WorldAppDelegate.h"
@implementation Hello_WorldAppDelegate
@synthesize window;
@synthesize MyViewController; //This is where the error pops up.. no declaration of property 'MyViewController' found in the interface
- (void)applicationDidFinishLaunching:(UIApplication *)application {
MyViewController *aViewController = [[myViewController alloc]
initWithNibName:@"MyViewController" bundle:[NSBundle mainBundle]];
[self setMyViewController:aViewController];
[aViewController release];
UIView *controllersView = [myViewController view];
[window addSubview:[myViewController view]];
// Override point for customization after application launch
[window makeKeyAndVisible];
}
- (void)dealloc {
[myViewController release];
[window release];
[super dealloc];
}
@end
Can you guys help me out? Thank you so much!
New in here.. I need some help, to be honest.. I just started out with the "Your First iPhone OS Application."
I get the error "no declaration of property 'MyViewController' found in the interface," in my "Hello_WorldAppDelegate.m" (here the error is in @synthesize)
My: Hello_WorldAppDelegate.h is as following:
#import <UIKit/UIKit.h>
@class MyViewController;
@interface Hello_WorldAppDelegate : NSObject <UIApplicationDelegate> {
UIWindow *window;
MyViewController *myViewController;
}
@property (nonatomic, retain) IBOutlet UIWindow *window;
@property (nonatomic, retain) MyViewController *myViewController;
@end
Which I think is where my 'interface' should be.
And my Hello_WorldAppDelegate.m is as following:
#import "MyViewController.h"
#import "Hello_WorldAppDelegate.h"
@implementation Hello_WorldAppDelegate
@synthesize window;
@synthesize MyViewController; //This is where the error pops up.. no declaration of property 'MyViewController' found in the interface
- (void)applicationDidFinishLaunching:(UIApplication *)application {
MyViewController *aViewController = [[myViewController alloc]
initWithNibName:@"MyViewController" bundle:[NSBundle mainBundle]];
[self setMyViewController:aViewController];
[aViewController release];
UIView *controllersView = [myViewController view];
[window addSubview:[myViewController view]];
// Override point for customization after application launch
[window makeKeyAndVisible];
}
- (void)dealloc {
[myViewController release];
[window release];
[super dealloc];
}
@end
Can you guys help me out? Thank you so much!
iPhone, iPhone OS 3.1.3