0

Im trying to convert a String directly in a Double.

@IBAction func addMemberButton(_ sender: Any) {
        let member = Member(name: nameTextField.text ?? "", saldo: saldoTextField.text ?? 0.0 , surname: firstnameTextField.text ?? "")

But this doesn't work at the "saldo" point. Is it possible to convert it directly to a Double?

Dávid Pásztor
  • 51,403
  • 9
  • 85
  • 116
TheClubApp
  • 29
  • 6

0 Answers0