[SOLVED] Set text string of text object in javascript block

How do I set the text value (string) of a text object from a JS code block ?

I have the reference to the object but can not find any references to setting it’s text value (checked the GD JS reference, and the auto-complete in the editor doesn’t show anything with ‘text’ in it).

I have tried a few random things like;
.text =“abc”;

but no luck so far :slight_smile:

1 Like

Just like with variables, you can use .getString() to get the text and .setString(“new text”) to change it.

objects[0].setString(“ne text”);
var text = objects[0].getString();


perfect! thank you! :slight_smile: