0
- (void)viewDidLoad{
    [super viewDidLoad];
    // Do any additional setup after loading the view, typically from a nib.[super viewDidAppear:YES];// Make self the delegate and datasource of the table view.
    self.tblPeople.delegate = self;
    self.tblPeople.dataSource = self;
    // Initialize the dbManager property.
    self.dbManager = [[DBManager alloc] initWithDatabaseFilename:@"sampledb.sql"];
    // Load the data.
    [self loadData];
}

-(void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender{                  EditInfoViewController *editInfoViewController = [segue             destinationViewController];
    editInfoViewController.delegate = self;
    editInfoViewController.recordIDToEdit = self.recordIDToEdit;
}

These three have syntax errors:

self.tblPeople.delegate = self; // Assigning to 'id<UITableViewDelegate> _Nullable' from incompatible type 'ViewBase *const __strong'    

self.tblPeople.dataSource = self; // Assigning to 'id<UITableViewDataSource> _Nullable' from incompatible type 'ViewBase *const __strong'

editInfoViewController.delegate = self; // Assigning to 'id<EditInfoViewControllerDelegate>' from incompatible type 'ViewBase *const __strong'
rmaddy
  • 314,917
  • 42
  • 532
  • 579
  • Could you show your definition code for `self.tblPeople` and `editInfoViewController`? If you using IBOutlet, you should set `(nonatomic, weak)` for ViewController. Or you have not assigned delegate like this `@interface ViewController () { }` – nynohu Nov 09 '16 at 05:13
  • Have you added the protocol identifiers to the interface (.h) file? – vadian Nov 09 '16 at 05:18
  • @vadian Do not add them in the .h. It's not public info. Put the protocols on the private class extension where they belong. – rmaddy Nov 09 '16 at 05:19
  • if you are assigning delegates then your current implementation file should also inherit from tableviewdelegate and datasource – ammar shahid Nov 09 '16 at 05:21
  • `@property (nonatomic, strong) id delegate; @property (nonatomic, weak) IBOutlet UITableView *tblPeople;` @nynohu – jeffrey organo Nov 09 '16 at 05:21
  • thanks guys. i just update my interface to @interface ViewBase : UIViewController – jeffrey organo Nov 09 '16 at 05:45

0 Answers0