cancel
Showing results for 
Search instead for 
Did you mean: 

Cancel button action/event

prathamesh_gandhi
Participant
0 Kudos

Hi All,

I want to cancel the event before it completes the processing.

i.e. I have 2 buttons on view as Approve & Reject. If user clicks on Approve and immediately want to stop the processing or want to Reject it.

Is there any way to stop/cancel the event from processing ?

or What will happen if user clicks on Reject immediately ? Will the reject action will get called ?

Note : It is custom application, and on successful processing of either action I am navigating screen back to initial screen.

Thanks In Advance,

P$G.

View Entire Topic
iftah_peretz
Active Contributor
0 Kudos

Hi Prathamesh,

It was hard for me to understand what you want to achieve. But, I think, you meant that there is case where the user clicked "Approved" and then during processing wanted to abort this action by clicking "Cancel".

If this is what you meant, then the answer depends on the process that was lunched. As this is vauge I will answer with some pointers that might give you some direction (more than that you'd need to attach a lot of screenshots/code etc.):

  • The "Cancel" button could trigger an undo process (say like a ROLLBACK WORK) and the "Approved" leads back to that view and not to the initial screen (you can have a "Back" button for this).
  • The "Approved" button can trigger a process that is on a new session/task and it is conditioned on doing something as long as no flag was set (in DB/memory - some cross platform visible to all) and that flag could be set if the "Cancel" button is clicked. Of course you'd need to fire some event that will notify the user that the process ended (or canceled) successfully.
  • Break down the "Approved" button process into several (up to you and the process) mile stones for which the user is prompted "Do you wish to continue?", "After this point you will not be able to terminate the process. Are you sure you want to continue?" - Well , you get the point.
  • Create another view/popup that could be open at any given time that could cancel specific/all process that are running (need to be sure you can implement this capability).