In this task, we will create a workflow with Receive and SendReply activities, and run a workflow as a WCF service. This workflow will accept two integer numbers and return their sum to the caller. We will use WCF Test Client to test the service.
Create a new WCF Workflow Service Application project and name it
ReceiveAndReply
; refer to the following screenshot:Open the default created
Service1.xamlx
. We need to perform the following actions:Add two
Int32
type WF4 Variables x and y to the Sequential Service scope.Click the View parameter… link of the
ReceiveRequest
activity and add twoInt32
type service parametersxIn
andyIn
as shown in the following screenshot:Right-click the
ReceiveRequest
activity and select Properties; the properties should be set as shown in the screenshot:Click the View parameter… link of the
SendResponse
activity and add anInt32
type service parameter named...