Am trying to port away from .textLabel.text, as per Apple but I can't seem to find the way to get the text I set.
I now set my cells this way:
let cell = UITableViewCell()
var config = cell.defaultContentConfiguration()
config.text = dbClass.nameList[indexPath.row].clientName
config.textProperties.color = .black
config.textProperties.alignment = .center
cell.contentConfiguration = config
But when I try to get the text of a selected cell (once the user hits the OK button) I can't seem to reverse engineer how to get the text.
let cell = myClientList.cellForRow(at: myInvsList.indexPathForSelectedRow!)
let config = cell?.contentConfiguration
dbClass.curMasterinvList = ?????? (can't find what property to read here
I even tried
let config = cell?.defaultContentConfiguration()
Hoping that the text would be in there, but the text there is blank, so am assuming that's just the standard config before I've changed it.
I have Googled as much as possible, but can't seem to find this very simple need.