Adding Button to a node dynamically

Hello I have a deicision tree node as shown in the image. I want to do 2 main things

  • Get list of button names(i,e. NodeA , Node B)
  • Add more buttons(eg NodeC,NodeD) dynamically on a button click

How can i achieve the above please help

Getting the names is highly dependent on your node template.

I suggest you look at the dynamic ports sample, which allows dynamically adding ports to a node:

This sample uses an itemArray to achieve this dynamic functionality. Instead of ports, you could add buttons.

Thanks a lot