How to unbind event bound with AddUObject()?

Hi,

So I have my custom event declared with DECLARE_EVENT_OneParam macro, and I subscribe it using AddUObject() method. How do I unsubscribe? There is no RemoveUObject() method.

For the DECLARE_DYNAMIC_MULTICAST_DELEGATE there is AddDynamic() and corresponding RemoveDynamic(), but how about DECLARE_EVENT?

There is a Remove() method, which expects something like FDelegateHandle as an argument. Am I supposed to use this method? If so, then how do I properly intitialize FDelegateHandle out of an instance of UObject derived class and a reference to one of its method (same data that I used in AddUOBject method)?

Regards!

If you look on api refrence all add function return FDelegateHandle

https://docs.unrealengine.com/en-US/API/Runtime/Core/Delegates/TBaseMulticastDelegate_void_Para-/index.html

And you can use it to remove the bind

https://docs.unrealengine.com/en-US/API/Runtime/Core/Delegates/TBaseMulticastDelegate_void_Para-/Remove/index.html

OK, I see… Thank you!

However, this forces mi to store all the returned FDelegateHandle each time I use AddUObject(), which is not very convenient. Is there no way of manualy creating my own FDelegateHandle instance out of UOBject pointer and a function reference?