How can i transfer a variable from a bp to another one?

There are multiple ways you can do this
If there’s a way for those two blueprints to communicate you just cast to it, otherwise you can use an event dispatcher.
An event dispatcher allows you to call an event when another event in another blueprint is fired.
Another alternative would be to use an interface.
Hope that helps!