Enable Email for All Microsoft Dynamics GP Workflow Steps

Microsoft Dynamics GPI did some work for a client a while ago where we created a lot of email steps in Microsoft Dynamics GP workflow after which the client decided they would be using email after all and needed email on those steps activating and a custom message assigned. Rather than going through each step manually and switching the email on, I created a small script to do the job for us.

The script was for a PM Batch Approval type so also enables the include Document Attachment option.

The highlighted section is the name of the E-Mail Message ID to assign:


UPDATE
	WF100003
SET
	EmailMessageID = 'AZRCRV PO APPROVAL'
	,Workflow_Step_Send_Email = 1
	,WFIncludeDocumentAttach = 1
WHERE
	Workflow_Step_Send_Email = 0

As always before running a script make sure you understand what it does, test it on a test system before deploying live and make sure you have a good backup before running and verify afterwards.