Dynamic text field size

Hello all,

how can i make the size of a dynamic text field exactly equall to the text inside it with out any margins on its borders.

Thank you.

Create your textbox and give it the INSTANCE name (this is important that you don’t set it as the var name) of “myTextBox” (just for this example, you can change it for your real textbox).

Add this code to a frame on the timeline…

myTextBox.autoSize = true;