1

I have a workflow that was created using the CRM workflow UI. Somehow the UI allowed me to create a workflow using a custom activity that had the SystemUserRole as an input entity. You cannot use this as an input entity because it is a many2many relationship entity. So although the UI allowed it initially, trying to open the workflow to edit it later cause an exception saying that CRM cannot 'retreive' the SystemUserRole entity.

So since I could not open the workflow in the UI to fix this, I exported the workflow and edited the xaml using some sample xaml from another workflow I exported which referenced the correct/intended input entity type 'Role'.

However now when I import the workflow back into CRM, the UI says:

Processes designed outside the Microsoft Dynamics CRM web application 
cannot be viewed or edited in the web application.

I have a couple questions about this:

  1. How did crm know the workflow was edited? I used CRM generated xaml to fix the problem and left everything else the same.
  2. I there a hash or md5 stored somewhere in the exported workflow?
  3. Can I generate a new hash to fool CRM into thinking that the workflow originated from the Web UI?
Bitfiddler
  • 3,942
  • 7
  • 36
  • 51

1 Answers1

1

Good news everyone! CRM 2011 does not know whether or not you edited the xaml, there is no hidden hash or other mechanism that ensures that imported xaml is generated solely by CRM.

However, if there is any inconsistency within the xaml, the misleading message above will appear.

In my case, each variable in the workflow gets a unique TypeArgument Name. I did not update the Name which I copied from the working sample xaml, to the TypeArgument name already being used in the broken workflow.

Once I fixed this, CRM happily imported the workflow and I could edit it.

Bitfiddler
  • 3,942
  • 7
  • 36
  • 51