Hi ,
Can anyone help me to trigger the real time workflow after the record has been deleted. I found there is the option to trigger before record delete. But i need to trigger after delete. How can i achieve this?
*This post is locked for comments
@Adam Vero:
One reason to run a synchronous workflow after delete is because (say your actions cause another [synchronous] plugin to run) then code that performs a query won't get the deleted row in the resultset, whereas if it's triggered before delete then it will.
[Pretty sure that's right, anyway! I figure you're correct about the commit but the difference is in whether the delete statement itself has already been run.]
Cheers.
Hi,
You cannot do this with workflow. Plugin is the recommended way to do this.
Mansoor
Use Plugin Concept for for this type of scenario.
Thanks
Santhosh
MS CRM Consultant
Why?
When it says "before" delete, it simply means that the workflow will be triggered by the delete action, but it runs before the delete is committed in the database (it runs in the same transaction). This enables you to use logic based on properties of the record, and if necessary to stop the deletion from taking place.
Do you have a really slow running workflow that is causing timeout issues with the transaction?
Hi pushpa,
In this case niether the realtime workflow nor plugin will work, only async plugin and workflow will work as realtime plugin/workflows needs context but as the reccord is already deleted so context is empty but in case of async the context is stored for the plugin/worklfow to be used later as its async so in that post delete context is available to async meachanism.
I think you need to create custom workflow/Plugin for this.
Below link will help.
http://blog.developers.ba/develop-create-update-plugin-dynamics-crm-2013/
Hi Pushpa,
Real Time Workflows can only run Before the Record is deleted. You cannot make then run after the Record is deleted.
If you want your logic to run after the Record is deleted and synchronously, I will advise you to use the Plugin instead.
Hope that helps
Thanks
André Arnaud de Cal...
292,111
Super User 2025 Season 1
Martin Dráb
230,934
Most Valuable Professional
nmaenpaa
101,156