Problem with items in inventory UI disappearing

New to blueprints so I’ve been following a tutorial on how to add an inventory UI where the player can pick up objects and then press tab to see them in their inventory - but the tutorial locked the camera when opening the inventory and I didn’t want that so I had to delete a few nodes and that’s now made it so when the player picks up an item, it appears in the inventory, but when the inventory is closed and reopened again the item is no longer there.

TLDR I could do with some help fixing/adding a node that will ensure the item stays when the inventory is opened and closed.

These are the lines in my first person blueprint relating to the inventory:


Unsure as to if this is relevant with the problem but this is the graph in my inventory UI, widget blueprint:


And my Inventory blueprint:

Thanks in advance

It looks like you are adding the item to the inventory widget rather than an actual inventory, so whenever you create a new widget, whatever was in the old one is lost.

The inventory should probably just be a set/array of objects and the widget takes the information from that.