Delete Button Event

Hi,

Is there any event handler or any method that will be executed when clicking on the delete button(bin icon) of a particular bpmn element, there are suggestions about shape.remove but I want to know before the element deleted or while clicking on the delete button itself.

Thanks

The DeleteShapeHandler is responsible for deleting shapes. You can intercept the delete action in a number of ways e.g. changing the context pad’s implementation, disallowing deleting elements using rules or intercepting the actual command. What are you trying to achieve in general?

hi philipp,

I want to show an alert window while clicking on the delete icon for that i need a event to emit.

Thanks

There is no simple event being fired in that case (except for all the events related to the command execution). Try modifying ContextPadProvider to achieve your custom behavior.

Thanks for the help philipp, let me try this

Can I stimulate the deletion command by code? I basically want to do the deletion command on an element but programmatically, without the user actually clicking the button.

Please do not necrobump old topics. Instead link to this thread from new topic.