Search code examples
iosswiftstoryboard

Set height UILabel to 0


Is there anyway to set the height of a UILabel programmatically? I've added a bunch of constraints to my .Xib files so every other label is dependent upon the one above or below it for it's positioning. It'd make my life so much easier if I could just use:

nameLabel.height = 0 

My .Xib looks like this:

enter image description here


Solution

  • plz take the IBoutlet of constraint height and set the height you wantenter image description here