locked
Invoke Workflow RRS feed

  • Question

  • In ParentWorkflow i am using InvokeWorkflowActivity to invoke another Workflow(child)

    Every thing goes fine but control is returning to Host two times - one from Parent and another from child.

    my requirement is Child should inform the parent and parent should inform host.

    i have used handleExternalEvent in ParentWorkflow to handle event of child .

    Event is raising in Parent but the control  of ChildWorkflow is also going to host.

    Is it the Workflow Behaviour? or can we achieve the above Scenario?

     

     

    Thursday, April 20, 2006 2:15 PM

Answers

  • Hi Ravi,

    From what you described this is what seems to be happening.

    The Parent WF invokes the Child WF. In this case we have 2 instances (parent and child) running under the same RunTime. This runtime is kicked of by our host. Hence indirectly the child instance also has the same host as its parent.

    When you say control returns to the same host does it mean the WF Terminated/Idled/Completed event handlers for both instances invoke the same respective method in the host. If yes, then this is the expected behavior.

    To add, you are doing right by using OCS activities for communication between the 2 workflows here.

    Thanks,

    Kushal.

    Thursday, April 20, 2006 2:49 PM
  • Hi

    OCS is basically object communiation service. The activities that we use for OCS are HanldeExternalEvent and CallExternalMethod ( receiving messages and sending messages). You can find an example in the following link using ExternalDataExchangeService.

    http://wf.netfx3.com/files/folders/communication/entry1921.aspx

    Hope this helps

    Elif

    Wednesday, December 20, 2006 2:06 AM

All replies

  • Hi Ravi,

    From what you described this is what seems to be happening.

    The Parent WF invokes the Child WF. In this case we have 2 instances (parent and child) running under the same RunTime. This runtime is kicked of by our host. Hence indirectly the child instance also has the same host as its parent.

    When you say control returns to the same host does it mean the WF Terminated/Idled/Completed event handlers for both instances invoke the same respective method in the host. If yes, then this is the expected behavior.

    To add, you are doing right by using OCS activities for communication between the 2 workflows here.

    Thanks,

    Kushal.

    Thursday, April 20, 2006 2:49 PM
  • What is meant by OCS activities?
    Tuesday, December 19, 2006 8:48 AM
  • Hi

    OCS is basically object communiation service. The activities that we use for OCS are HanldeExternalEvent and CallExternalMethod ( receiving messages and sending messages). You can find an example in the following link using ExternalDataExchangeService.

    http://wf.netfx3.com/files/folders/communication/entry1921.aspx

    Hope this helps

    Elif

    Wednesday, December 20, 2006 2:06 AM