The Problem SolverWIndows Workflow Foundation
HomeShow ChangesEditPrintRecent ChangesSubscriptionsLost and FoundFind ReferencesRename

Search

History

26-11-2007 08:21:375-10-2007 02:46:5417-11-2006 20:31:02

List all versions

External Data Exchange Not Raising Events
.

nogetricol

Summary
An event from a ExternalDataExchange object for the workflow is not getting raised.

If you are trying to raise an event from an ExternalDataExchange service the most likely cause of the problem is adding the service object to the WorkflowRuntime instead of the ExternalDataExchangeService. Calling the ExternalDataExchange service from the workflow will work just fine but raising an event will not work. If you are using C# and not testing for null you will get an NullReferenceException "Object reference not set to an instance of an object.".

Good code:

ExternalDataExchangeService externalDataExchangeService = new ExternalDataExchangeService();
workflowRuntime.AddService(externalDataExchangeService);
externalDataExchangeService.AddService(new MyService());

Bad code:

workflowRuntime.AddService(new MyService());
@}
Wiki Usage

This wiki site is supposed to be a shared resource. As a shared resource everyone is encouraged to add new content or modify existing content!

Enjoy the WF wiki.

Recent Topics