I am facing issue in multiple initialize event bus handler.I want to remove handler of event bus some how once it's task completed. how can I remove event handler?
As I know if object is singleton instance, then this event bus handler is initialized only once and no problem in it.
But if multiple instance of object, then handler is initialized multiple then while I am firing event, it will call all initialized handler.
Just Example: I created Add comment dialog box. user enter some comment in it. and click on save button before saving comments to database, it will signing comment data using sign certificate popup , In that sign certificate popup, on save button click that will save some audit info into data then RPC return back and in success method. Now in success method I have to call Add Comment dialog box using event handler and do continue for other operation of it.
So here Add comment dialog box have multiple instances, it will initialize multiple handler. and event fired for before opened instances also. here I want to do like if once comment operation completed for dialog box, then remove that action handler.
how can I remove event handler if my task for that panel's completed?