Page 1 of 1

Resizing A Label Field.

Posted: Tue Dec 21, 2021 3:53 am
by Googie85
Hi Guys!

I am trying to resize a label field based on the number of lines of text it contains. If I was to add a new line to a label field, how would I resize the height of the selected field?

Thanks for your replies!!!!

Googie.

Re: Resizing A Label Field.

Posted: Tue Dec 21, 2021 7:00 am
by dunbarx
Hi.

There is a very cool bunch of properties that contains the word "formatted". Check the dictionary. In your case, after you have loaded your label field with whatever text,

Code: Select all

set the height of field yourLabelField to the formattedHeight of field yourLabelField
Craig