Monday, April 1, 2013

SharePoint Designer: Error while Compiling

I tried to create workflow in SharePoint Designer:

The Error occurrs only, if the workflow contains a workflow lookup and i want to compile it.
In this case the following error-code appears:
Microsoft.Workflow.Client.ActivityValidationException: Workflow XAML failed validation due to the following errors:
Cannot set unknown member 'LookupSPListItemStringProperty.ItemId'. HTTP headers received from the server - ActivityId: 9aefe91b-ad3d-4942-a9d6-62b23573db09. NodeId: WFFE_IN_1. Scope: /spo/2066dfc3-753d-448e-8402-3a0b9b06492d/42fbc970-d795-4c3e-b511-3d6368d46642/8a0077c0-0b4b-45e4-bde5-07ece5ae2c20. Client ActivityId : 2114fc9b-50c5-c037-e339-58dfee5e3821. ---> System.Net.WebExcepti

It took long time from me to solve. I decided to Re-register service into my side using command:

Register-SPWorkflowService -SPSite 'https://myhost/mysite' -WorkflowHostUri 'https://workflowhost' -AllowOAuthHttp -Force

I reopened SharePoint Designer again and problem disappeared.


Michael Pushin said...

Thank you for that solution, Tarek! Your post saved me a lot of time as I tried a lot of things to overcome the issue and ran out of ideas what could I try else! I have added link to your solution to my blog.

Regards, Michael (

Anonymous said...

Muchas Gracias! This was a great help!!! Great post.


Khaled Moawad said...

Thanks a million Tarek. You saved me.

Khaled Moawad said...
This comment has been removed by the author.
Chan Krish said...

I got this error while trying to register service.

.\Register-SPWorkflowService : The term '.\Register-SPWorkflowService' is not
recognized as the name of a cmdlet, function, script file, or operable
program. Check the spelling of the name, or if a path was included, verify
that the path is correct and try again.
At line:1 char:1

Tarek Yehia Abd El Khalek said...

Run from Windows PowerShell for SharePoint 2013 instead of windows powershell

Unknown said...

I am getting the same problem with office 365 what should I do >

robot said...

I get the "The term '.\Register-SPWorkflowService' is not recognized as the name of a cmdlet" error from the SharePoint Command Shell. Any idea why?

Unknown said...

I have received the same error and I am trying to execute the PowerShell Command. What is the workflowhost in this script.. Please let me know

Unknown said...

I am able to execute the cmdlet 'Register-SPWorkflowService' but when it cames to the WorkflowHostUri it says that can't connect to the remote service at my site.
What should I do?

Anonymous said...

You saved me a LOOOOOOT of time. Thanks!!!