G
Guest
I want to hook events handlers but need to test of any event handler is
assigned or not.
I need something like this:
__event void OnEventHandler(Myfunc)
....
if (OnEventHandler) OnEventHandler(Myfunc);
else DoMyFunction(Myfunc);
....
This "if (OnEventHandler)" does not get accepted by unmanaged C++ 2002.
Any tips how to test this?
In Delphi this was possible.
I do know that it is a list.
Maybe somthing like "if (OnEventHandler.Count>0)" could do the trick?
assigned or not.
I need something like this:
__event void OnEventHandler(Myfunc)
....
if (OnEventHandler) OnEventHandler(Myfunc);
else DoMyFunction(Myfunc);
....
This "if (OnEventHandler)" does not get accepted by unmanaged C++ 2002.
Any tips how to test this?
In Delphi this was possible.
I do know that it is a list.
Maybe somthing like "if (OnEventHandler.Count>0)" could do the trick?