Getting an object by its name

Is there a way to get an animation montage by name ?
I want to use the BP function “Play Anim Montage” but i want to be able to change the animation to play, dynamically.

I can’t use Get All Actors of a class and compare the names because Anim Montage is not a class… is it ? I don’t find it.

I’m looking for a fonction like: Get Object by Name, but there is no function like this. A C++ version ?

Why needing this? Somewhere in your project you have x amount of Animations that you have created. You won’t create new ones while playing, will you?
So why not setting them to a variable in your Class by default? Create a variable of type Animation Montage and set the one you want to use. If you want
to use a different one while playing, make an array and fill in all different animation you want to use for this specific matter.

The reason is that i use retargeting for my characters and when i use it, Blueprint animation is ok, because it’s a copy of the original, but with a reference to new animations files.
Yes, but, in the event graph, there is also call to “Play Anim Montage” (i’ve to deal with, i would prefer to have all in blueprint animation, but it’s not my code).
So, the call to theses animations are not modified during retargeting.
I would like to change “Anim1” to “Anim1_Char1” for Char1, “Anim2_Char2” for Char2… automatically, not using a property and manually change all animations for all characters !

I think thereis no function to do that ? Can i make one in C++ ?