Problem with textfield

Hi all,

Ive used claudios scrollpane script from this threat: http://www.kirupa.com/forum/showthread.php?t=27214 especially for th ease function and added a function for dynmaic XML content. Its working fine.
The only problem though is that I have to manually adjust the lenght of the text field. Sometimes the text is longer than the text field can be created.
Is there a way to fix this problem?

Thanks for feedback,
m.