CRM 2013 - Receiving error from synchronous workflow on phone activity creation RRS feed

  • Question

  • I have a CRM 2013 solution that I am building that uses a Business Process flow to direct the user to collect information on a phone call activity.  The first two stages are Caller Info and Regarding Info.  One of the fields in caller info is to ask who the caller's relationship to the subject of the call.

    If the answer to this question is "Self", I would like to set the Regarding field to who the call is from.  I would like to use a synchronous workflow to accomplish this (I prefer workflows over plugins).  I will be adding a custom activity to retrieve this, but for the moment I am prototyping this by just simply hardcoding a contact to be set in the workflow.

    My problem is that I receive a very generic "An unexpected error occurred" error whenever set any synchronous workflow to run on the record create.  The workflow works on an update, but it really needs to set the regarding when the record is created.  Is there something special that has to happen in order to run synchronous workflows on record creation?

    Friday, November 8, 2013 2:20 PM

All replies

  • BTW, I thought I should assert my theory of what is going wrong here.  If I were doing this in a plugin, I would alter the values in the target rather than creating an instance of the CRM Service and attempting to do an update.  I believe the issue may be that you cannot use the update activity synchronously when an entity is being created.  Instead you need a means to follow the same process here that you would with a plugin.  Even though the interface indicates that this is run after the record is created, it would appear that the record is not saved yet.

    I'm actually hoping this is incorrect, but this is my only theory at the moment.  I would appreciate any advice on how to work around this.

    Friday, November 8, 2013 2:37 PM
  • Do we have a work around yet? I'm experiencing this issue as well when trying to run a synchronous workflow to update the subject of a custom activity after update and create.  The workflow works if I start it only when the record is updated but not when updated.   I also suspect that your theory is correct. 

    Thursday, November 21, 2013 7:15 PM