Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8934881
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T09:52:38+00:00 2026-06-15T09:52:38+00:00

So I have a PersonDoc.h file with the following code: #import <Foundation/Foundation.h> @class PersonData;

  • 0

So I have a PersonDoc.h file with the following code:

#import <Foundation/Foundation.h>

@class PersonData;

@interface PersonDoc : NSObject

@property (strong) PersonData *data;
@property (strong) UIImage *thumbImage;

- (id)initWithTitle:(NSString*)name gift:(NSString*)gift thumbImage:(UIImage *)thumbImage;

However, my PersonDoc.m file keeps giving me a warning symbol saying Incomplete Implementation. Heres the .m code:

 #import "PersonDoc.h"
 #import "PersonData.h"

 @implementation PersonDoc

 @synthesize data = _data;
 @synthesize thumbImage = _thumbImage;


- (id)initWithTitle:(NSString*)title gift:(NSString *)gift thumbImage:(UIImage    *)thumbImage fullImage:(UIImage *)fullImage {
if ((self = [super init])) {
    self.data = [[PersonData alloc] initWithTitle:title gift:gift];
    self.thumbImage = thumbImage;
}
return self;
}
@end

PersonData.h code:
#import

@interface PersonData : NSObject

@property (strong) NSString *name;
@property (assign) NSString *gift;

- (id)initWithTitle:(NSString*)name gift:(NSString*)gift;

@end

PersonData.m code:

#import "PersonData.h"

@implementation PersonData

@synthesize name = _name;
@synthesize gift = _gift;

- (id)initWithTitle:(NSString*)name gift:(NSString*)gift {
    if ((self = [super init])) {
        self.name = name;
        self.gift = gift;
    }
return self;
}
@end

In my viewcontroller, Im getting an error saying property name and gift not found on object of type PersonDoc. The following code is in my ViewController:

- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:           (NSIndexPath *)indexPath
 {
// Configure the cell...
// Create the cell
UITableViewCell *cell;
cell = [tableView dequeueReusableCellWithIdentifier:@"PersonCell"];

if (!cell) {
    cell =  [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleSubtitle reuseIdentifier:@"PersonCell"];
}


PersonDoc *person = [self.people objectAtIndex:indexPath.row];
cell.textLabel.text = person.name;
cell.detailTextLabel.text = person.gift;
cell.imageView.image = person.thumbImage;

return cell;
} 

I know it has something to do with the initWithTitle code in my .h file so can anyone show me the proper way how to do initWithTitle for both my .h and .m file? Thanks, I really appreciate any help guys!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T09:52:38+00:00Added an answer on June 15, 2026 at 9:52 am

    The initWithTitle in your header and implementation have different signatures according to the code you posted. Fix that, and your warning should go away

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Say I have two domain objects and a mapper interface. class Person { int
I have the following SQL code: select val.PersonNo, val.event_time, clg.number_dialed from vicidial_agent_log val join
Have following listener for keyboard ArrowDown event(it's key code is 40 ): window.onload =
Have the following code. The height is variable so the height of the floating
have written this little class, which generates a UUID every time an object of
I have a DTO type declared as follows: [Serializable] public class PersonDTO { public
Given the following Class and Service layer signatures: public class PersonActionRequest { PersonVO person
(Java Spring WebApp) I have: public class PersonValidator implements Validator { private PersonDAO d;
I have the following xml: <?xml version=1.0 encoding=UTF-8?> <sections> <section name=Options> <item key=HLVersionControlWebServiceURL value=http://www.personec.no/webservices/HLVersionControl/HLVersionControl.asmx
I have a problem with the hibernate named queries. My Entity: import org.hibernate.annotations.NamedQueries; import

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.