How do I use a line trace to intereact with another blueprint instance

So, I want my character blueprint to shoot out a line trace. When this trace hits an instance of my “door switch” blueprint want to door to open/close using a custom event in the “door switch” blueprint. I set this up so when the trace hits something, it checks whether the hit object is equal to a variable holding the “door switch” blueprint and prints a string declaring either success or fail. It returns fail every time even though a previous print string displays what object was actually hit and it prints the door switch every time it’s hit. If someone can tell me what I’m doing wrong that would be great. Thanks in advance.

if return fail because you comparing a valid actor( fited actor) with an invaid actor(door switch)
you have to use “Cast” to get the ref of the hited instance of tour switch

Here is an exemple

It worked. Thank you!