1
votes

I'm building a workflow that uses a WCF service .. but in the workflow project I didn't add a direct reference to the WCF service, instead I've added a reference to a project that has this service reference, but now the designer isn't opening and it's giving me the following exception error:

System.Xaml.XamlObjectWriterException: 'The invocation of the constructor on type 'OrderingSystemWorkFlow.RegisterOrderBill' that matches the specified binding constraints threw an exception.' Line number '25' and line position '34'. ---> System.InvalidOperationException: Could not find default endpoint element that references contract 'ServiceReference1.IService1' in the ServiceModel client configuration section. This might be because no configuration file was found for your application, or because no endpoint element matching this contract could be found in the client element.

How to solve this?

2

2 Answers

0
votes

Why not add a direct Service Reference to your WF project?

0
votes

When you add service reference of a wcf service in a activity library its turn into an activity and can drag drop on workflow. When you add service reference a config file is also added, copy the content of the config file basically that has a client and binding config section.

Please refer this link. http://blogs.msdn.com/b/endpoint/archive/2010/12/08/how-to-consume-a-wcf-service-from-a-wf4-workflow.aspx.