I'm trying to use a UILabel to display status messages.
public UILabel messageLabel;
messageLabel.text = "This is a status message";
But the second time I try to set the .text field it just superimposes the 2nd message over the previous message without clearing out the text that was there before. Even trying to null the .text field or using an empty string before trying to change the .text field doesn't work.
messageLabel.text = null // or "";
messageLabel.text = "This is the 2nd status message";
How do I clear out the previous text so I can cleanly display new text?