How to fix 'Must set an ExceptionManager in the ExceptionPolicy class using the SetExceptionManager method.'

0

I've got an existing project where I want to implement additional features to it, but even before I can do this, I experienced plenty of errors with it and after some time, managed to fix all the problems except one: "Must set an ExceptionManager in the ExceptionPolicy class using the SetExceptionManager method".

I've tried googling for solutions to this problem and the 2 solutions I've found gave me another error instead, With this solution: How To Use Exception Manager Enterprise Library 6.0

I get the following errors:

'ConfigurationErrorsException: An error occurred creating the configuration section handler for exceptionHandling: Could not load file or assembly 'Microsoft.Practices.EnterpriseLibrary.ExceptionHandling.Logging, Version=5.0.414.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040'
and 'FileLoadException: Could not load file or assembly 'Microsoft.Practices.EnterpriseLibrary.ExceptionHandling.Logging, Version=5.0.414.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)'

With this solution:

Migrate Enterprise Library 5 to 6

I get 'database factory does not contain a definition for setdatabaseproviderfactory' which I've also checked but it says it does provide this method so I'm confused on that part. So what exactly am I doing wrong on this part? I feel kinda stupid as I'm a novice in c# programming and am not sure on how to proceed.

c#
asked on Stack Overflow Oct 22, 2019 by tthh • edited Oct 22, 2019 by wazz

0 Answers

Nobody has answered this question yet.


User contributions licensed under CC BY-SA 3.0