1

I have an event receiver on an item updated event, when i manually update the list item, the event receiver is firing and calling the method, but when i update the list item through workflow step,when workflow is approved, it does not fire. i am deploying the solution as a farm solution.

public class CreateZohoTicket : SPItemEventReceiver    {
        /// <summary>
        /// An item was updated.
        /// </summary>
        public override void ItemUpdated(SPItemEventProperties properties)
        {  
            base.ItemUpdated(properties);

            if ((string)properties.AfterProperties["Status"] == "Approved")
            {               

                CreateTicket(properties);

                //calling a web service POST method in CreateTicket
            }          

        }
  • Have you used "Set Field in Current Item." tag for updating value in SharePoint designer workflow? – Dikesh Gandhi Jul 17 at 6:59
1

If you are using Set Field in current item action in your SharePoint designer workflow to update a list item, it will not trigger item updated or any other event receiver in list.

You will have to use Update list item action in your designer workflow, so when workflow updates your list item, item updated event receiver will be triggered.

Hope this will help you!

  • Hi Dikesh, Thank you for the reply, i am using 'update list item' in the workflow, setting the value of a 'Status' filed to 'Approved' in update list item step. – user6621250 Jul 17 at 14:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.