Difference between UIButton! and UIButton? in swift IOS -


Only now I'm starting to work with sharp language. I thus have initiated the buttons

  @Iboutlet weak var Sistmkastbtn: UIButton!   

I then I can set the title .setTitle () using the property.

What if I use? Instead ! While .setTitle () as

  showing error on UIButton, when you start? There is no member called 'SetTitle'   

Therefore, anyone tell me the difference between UIButton! And UIButton? .

Both are optional types. But UIButton! Optionally opening it is not open manually if you see the UIButton! , do not raise that your app will crash! << Code> Zero .

For more information on "Anplglikit unreserved option" Apple "The Swift Programming Language" section in the book.

Comments

Popular posts from this blog

java - ImportError: No module named py4j.java_gateway -

python - Receiving "KeyError" after decoding json result from url -

.net - Creating a new Queue Manager and Queue in Websphere MQ (using C#) -