I am trying to print value on my table view row everything goes correct but value is printing like
println("\(cell?.textLabel?.text)")
Optional("Some text") instead of "Some text"
Is there any way in swift to print actual value?
I am trying to print value on my table view row everything goes correct but value is printing like
println("\(cell?.textLabel?.text)")
Optional("Some text") instead of "Some text"
Is there any way in swift to print actual value?
It is printing an optional values so you need to unwrap it like:
if let yourCell = cell?.textLabel?.text {
println(yourCell)
}
Refer this Apple Document to know more about optionals.