I want to change the width of my label since my swift code. If possible, do it in a annimation prograssif for a change. Is it possible ? When I do:
self.lblChoice1.frame.size.width += 50
My exchange label width not ... Why? Thank you in advance.
EDIT : The first response is not working.
print(self.lblChoice1.frame.size.width)
self.lblChoice1.frame.size.width += 150
self.lblChoice1.contentMode = UIViewContentMode.Redraw
self.lblChoice1.setNeedsDisplay()
print(self.lblChoice1.frame.size.width)
This code displays me well in my console:
150.0
300.0
But my label size does not change the display ...