How to access a variable from another blueprint?

Hello everyone,
I started using UE4 about a month ago and I’m building a top down game which involves a hacker and the Police. My question is, when i press the “Hack Computer” button in the hacker overlay, I want the information to appear on the Police Overlay, which is currently hidden. I was not sure how to access the variable since it’s on a different blueprint but I watched a few videos that use the “cast” feature to access it. No one of them seem to help so i will ask for help here.
Thanks in advance.

You need to save the widgets you create as reference so you can access them from other blueprints. Otherwise they are pretty difficult to access without using things like “Get All Widgets” which I don’t recommend. Second you can’t set the visibility of something if you don’t have its execution pins connected. In your final screen shot you have an error below a cast node first because it isn’t hooked up and second because you are casting a player controller to a widget. That will fail every time because a player controller is not a widget. Check out this tutorial series it should help you understand what you need to do. Video #1 is about casting, video #25 is about creating references.

Additionally you can watch this one where I communicate between 2 widgets directly. You can see the steps you must take (although they may be slightly different if it is 2 view port widgets but the concept is the same)