标签: swift type-conversion
我正在尝试直接在Double中转换字符串。
@IBAction func addMemberButton(_ sender: Any) { let member = Member(name: nameTextField.text ?? "", saldo: saldoTextField.text ?? 0.0 , surname: firstnameTextField.text ?? "")
但这在“ saldo”点不起作用。是否可以将其直接转换为Double?