How do I reference my Blueprint Widget, to access its variables, in another Blueprint Actor?

I have some variables in my Blueprint Widget, but I can’t access it. When I put a reference to this Blueprint, which I have named as “UI_BP”, it finds the reference, but I get the error:

-Blueprint Runtime Error: “Accessed None trying to read property RefUi”. Node: Custom Event Graph: EventGraph Function: Execute Ubergraph Bp Main Blueprint: Bp_Main

"Bp_Main is my Blueprint Actor.

Thank you very much in advance.

Can you post your code or a screenshot of it?

I think the issue you are facing is that either the widget isn’t loaded or is unavailable for access because of privacy.

When you create a widget, it is a good idea to make it into a variable which can be easily loaded during gameplay.

Good afternoon.

Yes, of course. I try to make reference with the widget but it doesn’t let me, as if I put reference to a BP Widget or the same BP that I have, “UI_BP” and the first option, gives me that error and the second, has no reference, which is the error that I exposed before.

I have tried to make this option the other way around, to make the code that I have in the “BP_Main”, in the Widget, but I don’t get the option to have an event that starts the BP as the BeginPlay. Anyway, I would like to do everything in the “BP_Main”, but the widget reference is null and I don’t understand why, since I have taken as reference my own BP, but it seems as if it is not referenced in the variable that I want it to access.

I attach the code. Thank you.

PS: In the first picture of the “BP_Main”, I have compile, is that I did not do it before the screenshot.


From the Create UI BP Widget, right-click on the return value and make it into a variable. With that done, you should easily be able to access it and its data. You should be able to reference the blueprint and all of its content.

Good afternoon, can you tell me exactly how to do it, I don’t know how to do it.

I send you a screenshot of what I have in this text variable.

Thank you very much for your help. :pray:

I just fixed it my friend, thank you very much for everything @EliasWick .

But I would like to know the logic, why when I did it to yes it works and with the other not, if I made a reference also to my Blueprint Widget and let me access its variables?

Dejo la nueva imagen de como ha quedado:

1 Like