How to create a textField with numbers?

Hey there,

 

I simply want a text field which can deal with numbers.

So theTextField.text should be a Double and not a String.

 

How can I do this in an easy way?

 

Converting like this does not work because the Double should be optional.

let double = Double(theTextField.text)

 

Best,

Garrett35

Powered by WPeMatico

You may also like...

Comments are closed.