Building class and properties

I have created a node class, added a rectangle, added input and output ports, and finally added a label.

The label "new" is added like so:
nodelab.text = "new"
...(size, font, position, etc.)...
This is what the node looks like:
I also wanted to make the label a property of the class that can be read and updated, so I attempted to use the insert statement to save the gotext object:
Insert(1, Nodelab)
When I add the insert statement, I do gain access to the property, but the label is no longer displayed. It just goes blank.
In the end, I would like to be able to update the label using the class property.
Any pointers on this?

By doing the Insert, you are putting the label early in the node’s list of objects. That order is also the stacking order… the first things in the list are drawn first, so they are visually at the back. My guess is you put your label behind the rectangle. If you do .Add, it should be visible.

Thanks. Just getting back to this project.

I played with it, and inserting the objects in a particular sequence does the trick. It leads me to a follow-up question...
If I use 'insert' to add objects to my node, is there any need to use the 'me.add' method? It seems to be two similar ways to perform the same task. The 'insert' syntax seems like it gives a little more control as to the stacking order.