Unable to remove widgets

UWidget::RemoveFromParent() called on ‘/Engine/Transient.UnrealEdEngine_0:Hive_game_instance_C_121.notyet_dialogue_widget_C_1.WidgetTree_0.keyword_panel_widget_C_1’ which has no UMG parent (if it was added directly to a native Slate widget via TakeWidget() then it must be removed explicitly rather than via RemoveFromParent())

       This message shows up and i cant remove widgets using Remove from parent or Remove all widgets. Can anyone explain what this message implies?
  1. Could you show us a screenshot of your workflow?
  2. When removing from parent, are you plugging in the widget reference in the object reference input of “remove from parent”? I think, remove all widgets is a bad idea and I think that is what is causing that error.

I have a faint recollection of having a similar problem when I started out with UE and at the time I did not understand references so I got a lot of "none trying to read"s and stuff like that popping up. Not sure if that is what is happening for you though.

  1. I added the widget to the View port

  1. I tried to remove the widget by calling its class. It should work right since I’m calling all instances? I’m confused that the widget still shows. This screenshot is from widget event construct.
  1. So on the first image you might consider saving the widget output as a variable so that you can access it later when you want to remove it. Is this all inside the same blueprint and why are there so many wires going out from the create widget node, where do they go?
  2. Thanks for the pictures. Like I said I can be wrong about this but I don’t think calling that function inside of event construct is the right way to go. From what I know that gets triggered when the actor is rendered inside your scene. Or is this inside the Widget Blueprint?
  3. If you want to remove a widget from inside itself I think you can just trigger the “remove from parent” since the target is “self” by default. If you want to remove a widget from inside a widget like if you have a pop-up element or something then would imagine that you need to have a reference of it so creating a stored variable is the way I find is the most practical way with a “isvalid” just before.
  4. I have never used “get all widgets” but it looks like you are trying to do the same thing two or three times depending on what is going on inside that last function.

If this does not help then you might need to give us some more context on the setup and what you want it to do.