Can't find 'Add Child' node...

I’m trying to spawn a widget, then spawn another widget and add it as a child to the first widget. I’ve seen people doing stuff like this, for example:https://answers.unrealengine.com/questions/91033/how-can-i-add-buttons-dynamically-on-my-umg-widget.html

But no matter what I try, I cannot get the ‘Add Child’ node to appear.

Here’s trying to drag off the first widget: http://i.imgur.com/AkrkrG2.png

Here’s trying to drag off the second widget: http://i.imgur.com/OXQfl05.png

Did they discontinue the Add Child in UE 4.10.4? If so, how do you add a widget to another widget?

Or am I just doing something totally wrong?

Ok, so you can add children, but you have to do it in the widget. Got to the widget graph and create a function called something like addTimeWidget. Create the widget there and you can addChild, get child and more with some of the widget components.

So if you want this widget to be added, you can either call the function from the onCreate in the UIMenuBackgroundLayerWidget or you can drag off where you were trying to add child and call the function AddTimeWidget.

Ah, fantastic – thank you!

I said you “had” to do this in the widget, but you probably can find a way to do it outside the widget. In my humble opinion, it is best to add a child widget in the widget blueprint.

I had the same issue. I just uncheck “Context sensitive” ( check by default ) and the function addchild appears.

1 Like