TextBounds doesn't update in a script

Hello everyone!

I’m writing something where depending on how long the text is, it will place an image after it on the right.

I’m trying to use TextBounds but it doesn’t seem to update in a script…?

Script:

How do I make this work?
Is there an alternative option to this?

Thanks in advance!

1 Like

In the DevHub page, it says that you can only read it; not write (make changes) to it. Doing it may result in an error.

If this post helped you, click Solution. Thank you!

Regards,
David.

Based on your code, maybe you can use Position.X instead.

I’m not writing to it though. I’m trying to read it to get the TextBounds.

Thanks for all the help guys but I found out myself.

The script needed to be local. :cry:

1 Like