I get the following error when i try to run a console program which calls a Workflow 4 activity I created. Note the workflow compiles and runs without issue when executed from unit Tests or embedded in another workflow.
Could not load file or assembly 'Microsoft.Practices.EnterpriseLibrary.Logging.Database, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.
I am using EnterpriseLibrary 5.0 for logging and connection strings.
I notice that the path to the assemblies is as follows:
C:\Program Files (x86)\Microsoft Enterprise Library 5.0\Bin\Microsoft.Practices.EnterpriseLibrary.*
Looking at the Assembly Binding Log is see the following:
* Assembly Binder Log Entry (17/03/2011 @ 15:32:48) *
The operation failed. Bind result: hr = 0x80070002. The system cannot find the file specified.
Assembly manager loaded from: C:\Windows\Microsoft.NET\Framework64\v4.0.30319\clr.dll Running under executable C:\Development\Work\EquinoxeAISManagementSystemWorkflow\EquinoxeAISManagementSystemWorkflow.FeedManager\bin\Debug\EquinoxeAISManagementSystemWorkflow.FeedManager.vshost.exe --- A detailed error log follows.
=== Pre-bind state information === LOG: User = EQUINOXEAIS\pmckee LOG: DisplayName = Microsoft.Practices.EnterpriseLibrary.Logging.Database, Version=5.0.414.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35 (Fully-specified) LOG: Appbase = file:///C:/Development/Work/EquinoxeAISManagementSystemWorkflow/EquinoxeAISManagementSystemWorkflow.FeedManager/bin/Debug/ LOG: Initial PrivatePath = NULL LOG: Dynamic Base = NULL LOG: Cache Base = NULL LOG: AppName = EquinoxeAISManagementSystemWorkflow.FeedManager.vshost.exe Calling assembly : EquinoxeAISManagementSystemWorkflow.ActivityLibrary, Version=1.0.0.0, Culture=neutral,
PublicKeyToken=null.
LOG: This bind starts in default load context. LOG: No application configuration file found. LOG: Using host configuration file: LOG: Using machine configuration file from C:\Windows\Microsoft.NET\Framework64\v4.0.30319\config\machine.config. LOG: Post-policy reference: Microsoft.Practices.EnterpriseLibrary.Logging.Database, Version=5.0.414.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35 LOG: GAC Lookup was unsuccessful. LOG: Attempting download of new URL file:///C:/Development/Work/EquinoxeAISManagementSystemWorkflow/EquinoxeAISManagementSystemWorkflow.FeedManager/bin/Debug/Microsoft.Practices.EnterpriseLibrary.Logging.Database.DLL. LOG: Attempting download of new URL file:///C:/Development/Work/EquinoxeAISManagementSystemWorkflow/EquinoxeAISManagementSystemWorkflow.FeedManager/bin/Debug/Microsoft.Practices.EnterpriseLibrary.Logging.Database/Microsoft.Practices.EnterpriseLibrary.Logging.Database.DLL. LOG: Attempting download of new URL file:///C:/Development/Work/EquinoxeAISManagementSystemWorkflow/EquinoxeAISManagementSystemWorkflow.FeedManager/bin/Debug/Microsoft.Practices.EnterpriseLibrary.Logging.Database.EXE. LOG: Attempting download of new URL file:///C:/Development/Work/EquinoxeAISManagementSystemWorkflow/EquinoxeAISManagementSystemWorkflow.FeedManager/bin/Debug/Microsoft.Practices.EnterpriseLibrary.Logging.Database/Microsoft.Practices.EnterpriseLibrary.Logging.Database.EXE. LOG: All probing URLs attempted and failed.
I have tried the following to resolve the issue: - Setting 'Specific version' to False for all referanced EnterpriseLibrary assemplies - Recreating the app.config using the EnterpriseLibrary config tool again (and again and again :( - Deleting all references assemblies and adding them back in one by one.
I would be really grateful if anyone had further pointer as to how to debug this issue.....THANKS!