In the cellForRowAtIndexPath method, I have created a custom cell. The cell has a label to display project name. After assigned value to the label, it shows nil value when print. so that label could not display in the table view.
let cell = self.LeadsListTable.dequeueReusableCell(withIdentifier:"LeadsID", for: indexPath) as! LeadsCell
if let leadsDict: NSDictionary = self.leadsArray[indexPath.row] as? NSDictionary
{
cell.project_title?.text = (leadsDict.object(forKey: "project_title") as! String)
}
This way i used to display the value of the label
po print(cell.project_title?.text) (or) print(cell.project_title?.text)