Setup: Oracle: WorkflowGen Windows Service Error "Attempt to load Oracle client libraries threw BadImageFormatException"

Note: This applies to WorkflowGen version 5.x.

Issue

WorkflowGen Windows Service running with an Oracle database triggers the following error message:

Attempt to load Oracle client libraries threw BadImageFormatException. 

This problem will occur when running in 64-bit mode with the 32-bit Oracle client components installed.

Solution

As indicated in the error message, your WorkflowGen Windows services are running in 64-bit and try to load 32-bit Oracle client components.

Possible solutions:

  1. Install the 64-bit Oracle client provider to replace the 32-bit version.

    OR

  2. Force the WFG services to run in 32 bit using the CorFlags Conversion Tool (see http://msdn.microsoft.com/en-us/library/ms164699(v=vs.110).aspx).

As well, you have to make sure the COM+ components are installed and registered properly when migrating to a 64-bit system.