property Label.AutoSize as Boolean
Determines whether the control is automatically resized to fit its entire content.

TypeDescription
Boolean A Boolean expression that specifies whether the control is automatically resized to fit its entire content.
By default, the AutoSize property is False. The AutoSize property resizes the control to fit its entire content. Use the Caption property to specify the control's label. The AutoSize property has effect only when calling, so if you change the control's label at runtime, the control will not be resized, until you call again the AutoSize property. So, call the AutoSize property only when required. Use the WordWrap property to determine whether the control expands to fit the caption in the client's area. If the WordWrap property is True, and AutoSize property is called on True, the control's uses the original width to compute only the height of the control. The AutoSize property may be useful for single-line labels. The RequiredHeight property returns the height of the label required to display its entire contents. The RequiredWidth property returns the width of the label required to display its entire contents.