My SignupInfo.h
#import <Foundation/Foundation.h>
#import <CoreData/CoreData.h>
@class NSManagedObject;
@interface SignupInfo : NSManagedObject
@property (nonatomic, retain) NSString * firstName;
@property (nonatomic, retain) NSString * lastName;
@property (nonatomic, retain) NSString * sex;
@property (nonatomic, retain) NSString * email;
@property (nonatomic, retain) NSNumber * zipcode;
@property (nonatomic, retain) NSString * password;
@property (nonatomic, retain) NSString * retypepassword;
@end
My SignupInfo.m
#import "SignupInfo.h"
#import "NSManagedObject.h"
@implementation SignupInfo
@dynamic firstName;
@dynamic lastName;
@dynamic sex;
@dynamic email;
@dynamic zipcode;
@dynamic password;
@dynamic retypepassword;
@end
I am getting build error saying NSManagedObject.h file not found
I am using Core data model for SignupInfo
NSManagedObject is defined in a .h file that is included by <CoreData/CoreData.h>. Therefore, you do not need to declare it, and you do not need the #import statement.
Have same issue when I created NSManagedObject subclass in workspace.
Use follow declaration then the problem gone.
#import <CoreData/NSManagedObject.h>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With