There are a few things you can check in this scenario:
-
See if your table is linked to your class, usually by
@IBOutlet weak var tableView: UITableView!
-
Register custom table view cell:
self.tableView.register(UITableViewCell.self, forCellReuseIdentifier: "cell")
Note that you use “UITableViewCell” and the identifier “cell” even if your custom cell has different class and id. -
Dequeue your cell in cellForRowAtIndexPath:
let cell: MessageCell = self.tableView.dequeueReusableCellWithIdentifier("messageCell") as! MessageCell
Now you use the correct cell identifier.