The CallExternalMethod Activity

All of the code you’ve seen so far in this chapter has been to support a specific WF activity—the CallExternalMethod activity. The CallExternalMethod activity is designed to accept an interface and a method supported by that interface, and to call that method. The question is, who implements the method?

You might think your host application does, but that’s not quite correct. If you look back at the preceding section "Creating the bridge connector class," you actually find the method there. The data connector, which is tied to the ExternalDataService, implements the method. The data service, in turn, converts the method invocation into an event to which the host application subscribes.

It’s possible to use the CallExternalMethod ...

Get Microsoft® Windows® Workflow Foundation Step by Step now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.